What to do when the cold water valve on the water heater is welded on?
I think you mean soldered? A picture would help, a lot. There should be a flexible line going from the valve to the pipe system that detaches by loosening the hex-nut fitting. If there isn't a flex, you will be cutting it out and installing it properly, so that swapping out the next tank in ten years doesn't require calling a plumber, again.

I'm guessing yours looks like the one on the right in this picture. They should both look the one on the left. If this is your exact situation, I'd cut it out at the level of that other elbow on the hot side, install a valve there (perhaps mimicking that short horizontal run, to insure space for a power-vented unit's exhaust blower -to be installed in the future) and attach it with a new flex.



Picture source: How to Install a New Hot Water Heater, hubpages.com

The fitting could be heated with a blow torch to dissemble it for just a quick install of a dip tube and reassembled with no additional parts, PROVIDED, you are really good at sweating used copper fittings (not easy). If you're not and are going to have to call a plumber, I highly suggest having it re-piped as described so that you can swap it out yourself at some point when it dies.