1) it's an easy way to do antitrust without breaking up the economics of scale in the manufacturing side
2) dealers would keep money locally / respond to local consumer demand better and
3) dealers were smaller entities that would negotiate better with consumers because they wouldn't have a monopoly on local supply of a manufacturer's vehicles
None of these are regularly true today (and it's questionable how true they were at the time). There are far more viable automakers than when this regulation was originally passed and dealers don't offer better pricing or try to meet local demand more than manufacturers. Dealerships also typically aren't small local businesses anymore, but instead large corporate chains whose owners may live just as far away as the OEM.