dont know about the regs, sorry.
however you normally installl water softeners on the inlet to house on the cold inlet.
any decent cylinder will have sacrificial anodes, that rot away and are replaced annually in the service which in turn looks after the cylinder
Err! A bit grey this area. The problem is, some water heater manufacturers whose products have a high aluminium content in the heat exchanger, don't guarantee their products if a water softener is fitted.
The question has been asked of course "What about those water companies who part soften their water before it even comes into the house. Apparently the drill is to get onto the cylinder maker and ask them.