does light have mass?

No. It could not travel at the speed of light if it had mass.

It does have energy, however.

You cannot use E = h*(frequency) = mc^2 to get the energy of a (light) photon. The E = mc^2 formula of Einstein only applies to mass at rest.