If we took a modern society and erased all memory and knowledge of religion and somehow lengthened the life span to be infinite. And then allowed that society to progress, would religion be recreated?
Death is a constant in the world. All things eventually pass away. Even the world will one day. You may as well decide to legislate gravity away.
Religions do not explain everything in detail, they give meaning & coherence to a people. This though has to be qualified - it's not a objectified meaning - that can be grasped and looked at, and understood as this is what gives meaning; its pervasive and wrapped up in their being.
Although Dawkins made a fashionable that religion is a 'viral parisitical meme', anthropologists who actually study human beings & their culture as opposed to their biology, say the opposite - which is that its central to culture & society. It can take many varying & subtle forms within the same people, but of course central body of ritual & myth remains. In Lacanian terms - this is the Big Other.
One could argue that as European Christianity is slowly melting away that new religions will either be taken up or evolve. John Gray, the British philosopher for example understands Marxism & Neoliberalism as forms of political religion. Auguste Comte, the sociologist & one of the primary advocates of positivism attempted to turn this into a religion of man.
There is a recurring theme of some sort of life after death in all religions, would there be a need for religion if there was no fear of death?
One could argue, if one was to take an external objective view of religion, that to have a notion of life-after-death is to have no fear of death. Of course no religion justifies itself in that way.
There is a code of ethics built into religion, would there be a need for it with a code of law in the society?
Where do codes of law come from? Shelley said that Poets were the unacknowledged legislators of the world. This begins to make sense When you understand that in antiquity prophets & poets overlapped. Plato makes the same point when he has the philosopher-king as lawgiver & ruler of his republic; this should also be understood as the priest-king.
Religion is a way to explain the unexplainable, would it be needed if everything could be explained?
What makes you think we can possibly explain everything? Blake, the poet said 'the world is infinite in all directions'; meaning there is no end to its depth. We only see so much; and what we see we explain, so it appears to us we see & explain everything. In the last century when such a basic idea as counting or addition has undergone convulsions how can we conceivably say we understand the world completely?
Does man have in innate need to have an abstract figure which is greater then himself? Or without it, would we strive harder to be greater?
Gods do not have to be abstract. That is a relatively recent innovation. For most of the life of humanity icons & idols have been used. If a people was to worship a god(s) - is it conceivable that they would worship something less powerful than themselves? It cannot even be remotely be close. A veil of mystery must hide the divine from the material - for familiarity breeds contempt. All religions have a cosmology, within which is embedded an originary myth. Despite all the rhetoric of kings, emperors, philosophers, artists or physicists - no man has the creative power to make even a stone or a grain of sand. Their creative power is in refashioning - the fundamental creative act is transcendentally beyond them - to make a stone, to create a world takes a god or gods.