There are two books I've got in mind for this example: "The Early History of God: Yahweh and the Other Deities in Ancient Israel" by Mark Smith and The Great Transformation: The beginning of our Religious Traditions" By Karen Armstrong.
Psalm 82 is a popular chapter in the LDS and was even quoted by Jesus in the New Testament:
In Mormonism this is used as proof that ancient Israelites believed in the doctrine of exaltation where human beings can become gods. Jewish interpretations have focused on arguing that "gods" in this instance is a reference to angels, Melchizedek, a reference to the nation of Israel, or symbolic language for the temple. Christian arguments use this in conjunction with Jesus' statement John to argue that this passage means that we can all become one with God in the same way that Christian congregations were to be "one". Jesus is said to have claimed equality with God, and then turned to the people and explained that they too could become "one" with him and the father.Psalm 82 wrote: God standeth in the congregation of the mighty; he judgeth among the gods. How long will ye judge unjustly, and accept the persons of the wicked? Selah. Defend the poor and fatherless: do justice to the afflicted and needy. Deliver the poor and needy: rid them out of the hand of the wicked. They know not, neither will they understand; they walk on in darkness: all the foundations of the earth are out of course. I have said, Ye are gods; and all of you are children of the most High. But ye shall die like men, and fall like one of the princes. Arise, O God, judge the earth: for thou shalt inherit all nations.
What each of these interpretations seem to lack is a plain reading of the text which makes a lot more sense when viewed through the lens of modern archaeology and scholarship.
The people who eventually created the nation of Israel were Canaanites before separating themselves both culturally and geographically. The tribes of the north celebrated their heros, Moses and Abraham, while the tribes to the south were steeped in the Davidic tradition emphasizing Jacob and his chosen posterity. Their differing rituals and myths were combined in the bible, representing the covenanted alliance between their peoples, and singling themselves out as a distinct group. But even in their earliest days, they were all polytheists.
The earliest cult worshiped El, a sky god, and his consort Asherah who gave birth to a pantheon of gods. Each of the gods had their own shrines or temples and associated rites within their own geographic locations. They were those the bible refers to as the "sons of god", and each was assigned their own people. Yahweh was the god of Israel, but the people of Israel recognized the existence of other gods in the nations that surrounded them. The gods competed with one another, and were each worshiped for a different purpose, but Baal who brought rain was just as much a god as Yahweh who secured victory in battle.
Eventually there became political divisions between the northern and southern kingdoms of Israel. Along with these divisions, there also began a movement in the tribe of Judah to worship Yahweh alone and abandon the rituals associated with all other gods. Yahweh would provide everything for the people, the rain, the harvest, and victory in battle. Elijah and Elisha preach this message in particular, and after the northern kingdom was defeated and carried away by the Assyrians while leaving the smaller, weaker Judah in tact, the cult at Jerusalem won the theological battle.
So there's a transformation which takes place. A group of polytheistic Canaanites forms the nation of Israel. As that nation is broken apart and declines in power, their religion shifts towards worshiping Yahweh alone while still acknowledging the existence of other gods. Eventually, worshiping Yahweh alone morphs into the belief that there is no other god but Yahweh, and that he has transcended the world, becoming or taking the place of El.
Psalm 82 is an example of how Yahweh came to dominate and replace the Israelite pantheon:
Each nation had their own gods, but now Yahweh the god of Israel will inherit them all, or so says the Psalmist.Psalm 82 wrote: God [Yahweh] standeth in the congregation of the mighty [council of the gods]; he judgeth among the gods [Sons and daughters of El and Asherah]. How long will ye judge unjustly, and accept the persons of the wicked? [Gods respecting ritual over correct behavior / justice] Selah. Defend the poor and fatherless: do justice to the afflicted and needy. Deliver the poor and needy: rid them out of the hand of the wicked. They know not, neither will they understand; they walk on in darkness: all the foundations of the earth are out of course. I have said, Ye are gods [ex. Mot, Ashtar, Baal, etc.]; and all of you are children of the most High [Children of El]. But ye shall die like men, and fall like one of the princes. [They will be replaced by Yahweh] Arise, O God [Yahweh], judge the earth: for thou shalt inherit all nations.