How do I lock the player's animation

I want to lock the player animation, for example when the player dies the animation will play and the old character will stay like that and the player who died will be come a soul/ghost(a new character) for a few minuets and once its over he will then respawn.