I'm afraid you cannot add the same purchase levels mechanic to titans. You can however make a custom ability that costs resources that a specific amount of XP to titans. Perhaps you could add that ability to the titan factories and it would be pretty similar, the titan would just need to hang out by the factory for a while if you want to purchase levels for it.
Note however that titans keep their levels when killed, so this could make even vastly more powerful than they are now.