Legal water heater replacement
You should make two phone calls.  The first to your local building department, which should be able to answer all your code related questions. They may even have a handout or other documentation, that outlines the requirements of replacing a water heater. 

The second call should be to a local Rheem dealer, or directly to Rheem. They will be able to answer any questions you have about the equipment. 

Some things to watch out for:


Make sure you drain the old tank completely, as water can be quite heavy. 
When draining the tank, make sure you open the hot valves at fixtures. This will allow all the water to drain back to the tank. 
When opening valves at fixtures, watch out for mixing valves. These can accidentally backflow cold water through the hot water pipes, which would lead to an undrainable tank.
If you have to install an expansion tank, make sure you charge it properly. 
Make sure you know where to dispose of the old tank, as some municipal garbage collectors will not take water tanks.