Quoted By:
Dreams have less neuron activity than being awake does. That is why you are more "awake" and "aware" when you are awake. If your prefrontal cortex is having low activity in your sleep, your dreams will not be self-aware that much and you will simply watch the ride rather than be lucid. If more of your brain is active during a particular night then you will be lucid in the dream.
As far as I know, there is no known explanation for where the images and audio of dreams comes from actually. Memories are activated during dreams but strangely the part of the brain that is used for "imagination" and imagining imagery in your head is turned off during sleep, so people still have no idea where the images in dreams come from. Maybe it is just a byproduct of memories being activated? Nobody is sure.
People have "claims" about what dreams are for, but there is no concrete evidence for any theory of dreams right now, it is still just a mystery. The most credible theory is that it is just a byproduct of the brain being active during sleep and because it does not cause harm to the species there was no reason to remove dreaming evolutionarily speaking.