Connecting MongoDB on windows with mac

I have MongoDB working on my MacBook and I am using it in the flask app to save my form data. Now I also have a windows 10 system in my lab at the institution and I can connect to it via VPN and now I want to run my flask app on my mac and save the form data on that windows 10 system. I am using pymongo for connection.