In Yoga Vashishtha, the conversation between Sage Vashishtha and Bhusunda mentions how Earth evolved over time.
Sage Vasishstha asked:
You enjoy such longevity as would suggest that you have attained final
liberation! And, you are wise, brave and a great yogi. Pray, tell me
what extra-ordinary events you remember, relating to this and the
Bhusunda narrates such events in great details. I am mentioning only a part of the answer here.
…I remember that once upon a time there was nothing on this Earth,
neither trees and plants, nor even mountains. For a period of eleven
thousand years the Earth was under lava…
…[Later] apart from the polar region, the rest of the Earth was
covered by water. And then forests enveloped the Earth, and great
asuras (demons) ruled.
Then there arose great mountains, but without any human inhabitants.
For a period of ten thousand years, the
Earth was covered with the corpses of the asuras (daityas)…”
Bhusunda continues like this for quite a time, narrating more events. For more, read here: www.estudantedavedanta.net/The-Supreme-Yoga-Swami-Venkatesananda.pdf
Shloka number: 6.1.21.