very simple. dogs actually do not sweat like you and me because they have relatively fewer sweat glands. Instead, they pant i.e they stick their tongue out, to expel hot air and take in cool air. This acts as a thermostat or simply a cooling chamber!
I like @George Mochamah’s response.
I don’t think I could have a better reply to your question. Do you know that unlike humans who sweat everywhere, dogs only sweat through the pads of their feet? Dogs pant to cool themselves off. A panting dog can take 300-400 breaths (compared to his regular 30-40) with very little effort.