Theoretically this would be possible, however in reality the long (50mm?) endmill can not cut accurate enough, depending on required quality of work.I've never done anything like this, but could you mill slightly 'too deep', so there's less material to remove manually? Like this:
View attachment 360724
Yellow line is milling pass, then you've only got the two corners in blue to square off. Blue dotted line shows where the base of the key would sit, obviously it's the sides of the key that are taking the load not the base so it doesn't need much contact area, just enough to stop it moving.
The fit on the sides of this type of key determines the service life of the connection. Tigth fit and contact over the full surface area is the best, achieved only with a broach or a file and lots of effort. Milling as proposed can help to remove some material first.