I was in a conversation recently with a christian convert who seemed to operate on the principle that the tenants of a religion are real if there are religious experiences which indicate it to be so -- and it became clear they meant in dreams, but not exactly dream-like states. At the same event there was a muslim who had family members with visions (and so on). I made the point that localised to each region of the world are its own cultural beliefs 'replayed back' in such states -- this is especially noticiable in schizophrenia where psychosis-based delusions are heavily mapped through a cultural lens (eg., some spy service is contacting them through 5G; and UFOs in a previous era; ghosts before then; and devils before then).
It does seem plausible that lucid dreaming offers a plausible explanation of religious 'visions' which occur in well-functioning people; and likewise a mechanism for why they are so encultured -- with gods of one locale appearing to adhearents there.
And if lucid dream were previously much more widespread, this offers an additional benefit of religious mythology, which is narrative material for the construction of these dreams.