How do I script it so that the player morphs after a key is pressed and an animation is played?

As the title implies, I want to know how I can make it so that when a key is pressed, an animation plays and the player is morphed into a different model. I have no clue how to do this, if anyone could link a tutorial that would be very appreciated