Firstly please don't make the mistake that our prehistoric ancestors were less intelligent than ourselves we just have more education than they did.
I think Gods evolution went something like this:
The tribe's leader has a problem to solve, how to control the tribe? He knows the problems that uncontrolled people can do. Hunt one animal too much and it disappears for example. He has a light bulb moment and thinks I know I'll scare them into not doing that. He invents the spirit world and assigns different spirits for different everyday things that need careful handling and so reduce the excess' we humans can go to. A moral compass if you will but we humans are scallywags and will insist on inventing new things and as a consequence the list of spirit's increase. This means they become less and less credible to the young of the tribe. The tribe is getting bigger and bigger and the young always ask bloody stupid questions that, by accident, reveal a fundamental truth. The current tribe leader (a clever bugger) decides that too many spirit guardians, is just too confusing, especially as the number of new inventions begin to increase. He decides the simplest way to achieve this is one spirit guardian and so God becomes that guardian.