Why do you shiver when you have a fever?
When you have a fever, your body tries to compensate for a higher target temperature on your internal thermostat.
Normally your body has its internal thermostat set to around 36.8°C. A fever raises this thermostat setting so the normal temperature regulation mechanisms activate to try and correct this. This includes shivering and hiding under the duvet. Your skin may be hot to the touch, but your body temperature is still lower than the thermostatic target temperature, so you feel cold inside.