The idea that religion has "evolved" in a linear development is a popular one, and one that seems intuitively sensible. However, there is little evidence for this theory. The hypothesis of a linear development originates primarily with the Modernist intellectual movement, specifically the work of James George Frazer and his book The Golden Bough. And it is, admittedly, a very captivating idea. But it belies a lot of presumptions on the part of the Modernists--notably Darwinian evolution as an intellectual paradigm, and the belief in a (rather Eurocentric) single global narrative. Secondarily, in part due to these presumptions, Frazer and others like him did not have due diligence with scholarship, and researched only so far as to confirm their existing biases and hypotheses. Some of these hypotheses were iconoclastic at the time, even scandalous, but nevertheless their research was not deep enough and thorough enough to truly investigate their subjects. They warped the evidence, even if it was unintentional, to fit their theories.
Religions have adapted to suit their changing times. So it has "evolved" in a sense. But it is not a linear progression. There is no "perfect" system that religion as a whole is moving towards. Indigenous religions are not necessarily "more primitive" or "less advanced" than other religions. And this belies, again, the presumptions of the Modernist movement: their Eurocentric and colonialist attitude is that Western civilisation, specifically the 20th century scientific, Christian, Western European civilisation, is the ultimate point of development for society, religion, economy, et al. It is, ultimately, the White Man's Burden applied to the history of religion. And it has no place in modern anthropology.