You're lucky if you have a hex head to put a standard socket/wrench on. On my bike it is a 17 mm inverse, needs an "allen" wrench to turn. I had to kludge up a tool to get those loose.
The problem is that the bolt is threaded into a part inside the tube that is essentially free to turn. You can turn it with a wrench all day and never get it to break loose. Hitting it with an impact wrench is the way to go.
If you don't have the impact wrench there are other tricks. It helps to loosen those bolts before you disassemble the top of the forks as the spring tension will put a little more drag on the inside piece and provide a little resistance to turning. Set the forks on the ground, well supported, with the wrench on the nut and extending horizontally. Now hit the wrench with a hammer. The idea is to get a sudden impact into the bolt so that it will come loose rather than turn the inside piece.
If that doesn't work you can take the forks apart then insert some sort of object to push on the inside piece to provide some friction. I know people who say that they used a broomstick for this purpose.
Note that you need to do the same thing when you reassemble, you need to get the bolt reasonably tight and to do that you either need impact drive or to hold the inside piece.
Rod