Shift-clicking pumpkins/skulls puts one on head and moves the rest.
Put a stack of pumpkins on your hotbar and ensure your head slot is empty. Shift-click the pumpkins. You'll notice that one was moved to your head slot and the others were moved to your inventory. The expected behavior is probably for one pumpkin to be placed on your head, and for the others to not move.