the door is made of 3 parts, the chassis, the window frame and the finish skin, if the skin is dented the skin is replaced and painted, if the door chassis is bent the entire door is replaced, the window frame is a very tough job to remove and align hence it is replaced with door chassis.
The front fender is also considered finish skin and is replaced if dented (dented metal is stretched metal and when straightened will be a bit larger than original)
the rear fenders (1/4 panel) is welded to the body structure and is replaced by cutting and welding - its a very intricate process as to not overheat the metal. Care is taken to ensure the crush zones are not impacted by the welds. The skin has no part in safety of the car, its the metal unibody that is important.
The lower panels (sills) are part of the structure of the car and is very important to passenger safety in the event of a crash. It is repaired usually by cold pulling or if the structure is severly damaged - then very large pieces are replaced (welded in place)
the above are very expensive repairs and hence cars are scrapped.