Do you really want to pay an attorney $300 per hour with a big retainer for this? If you do, you can just google tenants rights attorney for your city and you'll come up with plenty to call.
If you'd rather not do that maybe I can give you some guidance. I've lived in AZ for over 40 years and 20 of those years I had rental properties.
Answer the following:
1 - What city are you in?
2 - What kind of apartments? Big complex - multi story? Small complex, duplex, fourplex? Somebody's condo?
3 - Are you on a written lease? If yes, what is the expiration date? If you are on month to month without a written lease, what day of the month is your rent due?
4 - How much is your rent?
5 - What date did you first move in?
6 - How much of a security deposit did you put up?
7 - What date did you discover the condition of the water heater?
8 - Does it still produce hot water in spite of the leak and the rust?
9 - How and what date did you first notify management? In writing, by phone, email, text? How and what date did you get a response?
10 - Is the management office on the apartment grounds or is the management company located somewhere else?
11 - Is the water heater the only issue or are there other issues that make the apartment "unsafe"? Explain.
I have good reason for asking all those question so please answer each one and number your answers to correspond with the questions.