The treads for the lens mount should be exactly the same, it is the M39 (39mm) Leica screw mount or LTM.
Some of the earliest Feds, those made before and during WWII, used the same thread mount, but had non-standard lens to flange distances (the standard for LTM is 28.8mm +/- 0.02mm). Those lenses will fit the Fed-2, but the photos will be out of focus. They are not very common.
If the threads look different to you, you may be observing the lens focusing helical itself from the back of the lens. That is a different pitch and diameter than the actual lens mount thread.
As long as you have both the Fed-5 and the Fed-2, you could try and interchange the lenses. They should interchange readily.
Some Fed-2's have a rangefinder cam that hangs too low in the lens mount throat. It can prevent some lenses like an Industar-61L/D from engaging the rangefinder cam properly. It can also scratch the back element of a Jupiter 12.
To see if you have that problem, mount the lens very carefully. The first time you try this, it may help to remove the camera back and lock the shutter open at B with a locking cable release. That way you can watch the lens clearance from the back.
<a href='http://www.rangefinderforum.com/photopost/showgallery.php?cat=500&ppuser=117'>My Gallery</a>