Medieval writers divided history into periods such as the "Six Ages" or the "Four Empires", and considered their time to be the last before the end of the world. Who first divided history into the ancient, medieval and modern periods