Wrong with script

What’s wrong?

if(Input.GetKeyDown(KeyCode.LeftShift) {
    transform.rotation = Quaternion.Euler(20,0,0);
else
    transform.rotation = Quaternion.Euler(90,0,0);

Input.GetKeyDown returns true for only ONE frame. On the next frame it returns false.

So, if you are willing to keep the rotation value for more than one frame (that is, as long as you keep pressing the LeftShift) you should use Input.GetKey instead.