Okay so before you go commenting bellow saying this is bullshit let me explain
so remember in the episode the cutie mark chronicels when celestia said ive never seen a pony with that so much power before in the flashback(i think herself is included)
so celestia distracted her and sent her to ponyville to make friends to distract her from defeating her
and shes also preventing her from entering the canterlot archives cause there is so much powerfull spells there like time travel and more and if she reads more of those spells and learn them she might defeat celestia in the futere thats why celestia was there when twilight was looking for the time spell