There are two thing affecting DOF, aperture and magnification.
I calculated the 50mm at 5metres and the 85mm at 8 metres and the 85mm has less DOF.. Wow!!!
In this example the magnification is different. Compare 50mm at 5m and 85mm at 8.5m for a comparison. If you use 85mm at 8m then it's a larger magnification than 50mm at 5m.
In theory, if you take a photo of a 2D subject, at same magnification and same aperture, DOF is the same, but for a theoretical 2D subject there is no DOF. For a 3D subject, changing the distance and FL will keep magnification the asme only for a theoretical 2D area of the subject (i.e. the precise spot you are focused on), so different parts of a 3D subject have a different magnification as a result.






