Features of nuclear reactions induced by ultracold neutrons passing through thin films