The temperature of the body is maintained by the certain actions that the body does in extreme conditions to maintain the temperature about 98.6°F.
If the body is in chilling conditions then there are chances that the body will be in hypothermia condition and to control the temperature the brain gives the signals to the muscles of the body to contract and expand very speedly.
When the surface of the body gets too chilly then the skin receptors sends the signals to the brain which gives signals to the muscles to shiver and in extreme case the chattering of teeth also takes place.