Hello Damiano,
If you open a port on your localhost where your Python API listens to you can basically shoot on your local host port and test it all locally. It sounds maybe easier than it is in some cases because you have a firewall and other security measures, and also mendix have some security measures in place on their outgoing and incoming calls.
But we managed to do it so don't give up
Hope this helps,
Good luck!
Any service or program that is exposed as a REST API can be integrated into mendix (not only mendix to any Backend or Fullstack system)
As per your research you got Flask, which is fine. You may do a springboot backend which exposes REST API (the java stack) or a ExpressJS based backend which uses NodeJS. All will work :)