in the first line you create a variable with the name of "head" that refers to the "Head" node before the scene loads.
in the second line you started the PhysicsProcess(delta)
that I'm not sure what it means but what I understand is that it does what's inside it every physics frame.
in the last line you create a variable every physics frame with the name of
"headbasis" that stores the transform(position, rotation, scale) of the head but the basis
thing is what I don't understand, I'd like to see the tutorial that you got this code from.
so you basically store the head's transform every physics frame.