Myths are anthropomorphosized explanations for natural phenomena and cultural conventions. In locations that have annual cycles of seasons, divine figures perform actions that have magical consequences. Days become shorter and plants die because the person in charge of these things is out of commission for six months. (In cultures with a dry season / monsoon cycle, the symbology would be different.) Every culture will adapt elements of a similar culture's myths to fit their own situation. Nomadic herders, steppe agriculture and river agriculture may have similar characters but their functions will be adapted to local conditions.
The reason for these myths to to make it easier to remember what happens every season. A story is more memorable than a list, and it provides reassurance. These events aren't chaotic acts of nature, it's just Set tricking Osiris again. Nothing will get too far out of hand.
Not all myths are climatic. Some deal with the nature of human relationships. Why is there evil in the world? What are the responsibilities of tribe members and why? No human being would be able to claim the authority to establish universal rules of conduct, or to have brought about the prevailing moral conditions, so the reponsibility is placed on long-dead heroes and divine superbeings.
The commonalities of myths are sometimes superficial (same act, different meaning), but they are all effective images that help fix cultural stories in peoples' minds. Caves, fires, knives are all dramatic items that everyone understands. Seduction, betrayal and abandonment are themes that allow change to happen, usually to explain why things aren't as good as in the old days.
Rituals are another way of telling these stories, acting them out by strict cultural rules. Sometimes the ritual overshadows and obscures the original story, such as when the culture changes and the original story no longer fits its communal life. There's still a connection with the past, but the past is no longer recognizable. We do and say these things at this time and place because that's what we do. Current Western culture is not as connected to the land and climate as people were before supermarkets, central heating and airline travel, but there are vestiges in the holidays we celebrate. We always do it, but we're not sure why.