green screen to transparent with ffmpeg
Output by MP4 defaults to the H.264 codec for the video. H.264 does not support alpha.

You can output to .mov with a video codec -c:v of png or qtrle. There are others but they have restrictions on resolution and framerate.

You can't use the overlay filter as it doesn't output to a pixel format with alpha. So, just the chromakey filter, and no color source.