Early religion is just another form of ontology, not that different in character from modern philosophy. It was just that back then knowable, material facts were scarce, and ideas about creation and spirituality were popular.
When you break it down religion comes into existence when people sit around trying to figure out what the hell is going on. Imagine being a prehistoric hunter gatherer in Africa. You know you exist, you know animals exist, but you have absolutely no such thing as a scientific explanation for these phenomena. So you sit around drinking beer with your friends, concoct stories and possibilities, and pass them on.
It's easy to get caught up in the institutionalization of religion, but you're right, back then this is just how we engaged with the world.
I don't think that is true. That's not what myths are or what they are for. Netflix is full of modern myths we enjoy telling each other. We like this. We like telling stories to one another that we know are fictional. We use art to explain and explore facets of reality.
What makes ancient religious myths special is that writing and spreading written stories was expensive. Most often these stories were spread orally. What shaped ancient mythic traditions is more a question of available technology rather than any conscious attempt to explain stuff. I mean... obviously. The people who first came up with these stories obviously knew they were just making shit up.
Over time these ancient traditions keep retelling the same story over and over until it sticks and we think it's true. Since we have no evidence the world isn't riding on the back of elephants who are standing on a huge turtle we might start treating it as truth.
And this isn't unique to the ancient world. UFO stories have a similar pattern. Similar stories keep being repeated until a share of the population start believing it. Or conspiracy theories. For whatever reason this is a part of human psychology. And this is going on since after the birth of science.
This is an apt quote.
"When we dream alone it is only a dream, but when many dream together it is the beginning of a new reality."
/ Friedensreich Hundertwasser