Yes, the motors all have heaters. A fair bit of the energy budget per day on the MER rovers (now MER rover) goes into preheating the motors. You can reduce the energy required by waiting until the afternoon, so they get some natural heating after the overnight cold soak. But you still need heating.
There was an attempt to develop motors for Curiosity that used a dry lube and could operate at much lower temperature. However that development didn't pan out, and the Curiosity motors also need to be preheated before use.
The motors are built using the same approaches as the brushed (MER) and brushless (Curiosity) motors used on Earth, though there is special attention to the gearboxes to keep out dust and have long life.
As for your Tesla Model S on Mars, even harder than pre-heating the motors would be pre-heating the battery. The energy required would be huge due to the mass of the battery. Also you'd be in a bit of a pickle trying to warm the battery with energy that you can't get from the battery because it's so cold.
Your DeWalt hand drill might work if you preheat it and you have a power source for it. Though you may need to worry about heat dissipation if it's under load, e.g. drilling something tough, since the convective cooling in the thin Martian atmosphere will be negligible.