There is a more easy way to do an UEFI installation on an iMac 2011 as long as you have only installed a single disk. If you have a second cheap USB disk and a second Mac install High Sierra including web drivers to this disk using this Mac. Boot the iMac with your M4000 from this new disk. Prepare the Win 10 USB boot stick and install. Details may follow if you can go this way.I plan to do so, but I got this crazy idea last night. I'm wondering if my p5 State issue has to do with running in legacy mode. Also, it takes about a minute and a half to boot to the windows login screen and have video display even with my SSD. In order to fix this I think I'm going to reinstall the 6770m and install High Sierra which should support the Maxwell ii based M4000M when I swap it back in. I can use that to install rEFInd, and then shrink High Sierra to about 60gb and reinstall windows in UEFI mode. I will install TeamViewer in both OS's and then reinstall the M4000M and update drivers through TeamViewer. Then hopefully i can still see the rEFInd boot loader and shorten the boot time significantly.
Edit: maybe I need opencore instead of rEFInd? I read somewhere that rEFInd worked for video with unsupported GPUs.
Have you tried OC to use as a boot selector emulation like we do with AMD cards?