I have the MG506 and the manual specifically cautions that the shaft must be prevented from free wheeling. I suspect your 507 is the same.
Just a note that ONLY mechanical gear boxes can be locked like you ask about. These are hydraulic gearboxes and as pointed out when the engine is not running the gear box has no pressure so NOTHING can be locked.
Typically only very small gearboxes can be locked as they are mechanical, not hydraulic.
Figure out how to secure that shaft. You must also KNOW which direction the shaft will spin when towed. Many single engine boats have a L.H. shaft rotation so when viewed from behind the engine, looking forward, the shaft will rotate CCW. Mine is like this.
Often a large pipe wrench can be used. It must be oriented so the teeth grab the shaft or the coupling as the shaft tries to rotate. There is a direction for it to work. The wrong way and the wrench will simply slip.
The teeth will leave marks but they can be filed off later. The marks are not heavy.
I have done this on two occasions. I also use a piece of 3/4 plywood , about 6" x 6", between the wrench handle and the hull to spread the load. I carry large Tyraps and use several of them to ensure the wrench stays on the shaft or it may fall off. In my case the shaft rotates in a direction, CCW as above, that the wrench MUST hang upside down to grab and that means its natural tendency is to fall off.
You could also use a heavy rope wound around the coupling several times for grip and then tied off. But you must sort out where to secure the rope ends to develop that grip.
Go to Twin disc and ask if they can supply a manual or try Ebay as they do appear from time to time. Be patient. It is worth trying to get one and from what I've seen they are not a lot of money especially compared to the cost of doing something wrong.