The Cargo Gods
Cargo cults first started showing up the Melanesian region during colonization and expansion periods as well as during the world wars. These cults are based around the idea that travelers coming through the region were aided by gods who would send the travelers gifts in the form of large cargo shipments. For the natives it was assumed that these cargo shipments and the goods they contained had to be gifts from gods because they never saw these travelers build or make any of these things.
So in order to hopefully trick these gods into giving them these gifts of cargo, the natives began rituals that mimicked the travelers who were receiving this cargo. Some cults even constructed fake airplane runways, call towers, and dressed in outfits that looked like troop outfits. They would patrol these fake airstrips mimicking the soldiers in hopes that the gods would grace them with cargo.
If you'd like more information on the cargo cults of the south pacific following WW2, follow this link: http://www.sjsu.edu/faculty/watkins/cargocult.htm
A Recurring Theme
All religion is born from a single statement. It doesn't matter how intricate and detailed these religions are now, they all started from a single idea. Just like the cargo cults, every religion that exists started with an idea that can be stated as such; "I don't know/understand, therefore god." When these pacific island natives saw technological marvels that they didn't understand and didn't know where they came from, their answer was god. When our earliest ancestors dreamed up the idea of pantheism, that the earth and nature are god, it was because they didn't understand themselves or the world around them... therefore god of course. As I've said before, every god is a god of the gaps.
Given the example we have from cargo cults, it becomes very obvious how religion is born. It is born of confusion and often fear. We imagine answers when we can find none. We invent gods to fill in the gaps in our knowledge and understanding. The problem with this is that we're also stubborn. Even when actual tangible answers present themselves we often will still favor that imagined answer rather than the honest truth. Most often we do this because that manufactured answer is comforting, and why wouldn't it be... we did after all manufacture it to ease our troubled minds.
The Big Shipment
Just like the cargo cult followers, most religious people are waiting for the big payout from their god. They're waiting for their heaven and eternal bliss, or something like it. A harem of virgins perhaps? Maybe a land of milk and honey. All the posturing and tradition are simply about appeasing the gods and trying to earn their favor and all in the hopes of some big payout. The reason for this is that life is hard and people want to think that we're working towards something.
So what began as a simple answer to where everything came from has evolved into this sort of perverted Christmas story with gods playing Santa Claus by taking names and handing out gifts or punishment. And in the end all religion presents itself as some perverted cargo cult whose followers are constantly waiting on the cargo gods to deliver the big shipment. What we have now is a world full of people waiting on Ed McMahon to knock on their door and hand them a big check, only instead of Ed it's an invisible man in another dimension they're waiting on.... And isn't that just the silliest thing ever?