I imagine that dying gives a person a great deal of perspective on things, so that when one would normally interfere with the events of the galaxy instead there’s a case of extreme passivity and letting things be. Yoda didn’t destroy anything except a rotting stump, and only because he knew that Luke needed to get beyond his hatred of Jedi dogma. He probably didn’t even change history, since Luke was about to burn it down anyway.
It was little more than a mischievous trick, totally in keeping with the slightly crazy second most powerful Jedi in the galaxy.