Well, fretting is something that includes a lot of stretch and tension. So, it is certain that you will have muscle aches, and your hands will hurt while fretting. We need to grip the fret hard for perfectly sounding strings. So, this is why due to tension, pressure, and stretch, your hands hurt.