When I was in grad school, we visited a studio in Detroit area that does a lot of car "photography" for the big three. Actually, most of it was CGI. What they will do is, they will send a team out to the desired site to collect environmental data, such(basically to be able to create a HDRI environment), and then they will render the car in the HDRI environment to show an accurate lighting and reflection.
Sending a team out there isn't cheap(desert, salt flats, mountain, city etc), but sure beats having to ship the entire car there. You can render a perfectly clean car in the desert, which is impossible in real life. They can also collect data at different times of the day to capture mid noon or sunset or night conditions. Also, they won't risk new cars being exposed prematurally in the real world.
But photography is only the easy part. They had lots of servers assembled as render farms to run those high res and highly detailed renderings. After that, they have a team of guys to photoshop it to perfection, also takes a long time.
The same also goes for motion pictures, like tv commercials or promotional videos etc.
They still have full size photo studios to shoot whole cars, but as you can imagine, that's getting used less and less these days.