First of all, you will need a developer account for either Android and iOS. For Android you pay a one time fee of 25 dollar, for iOS you need to pay 100 dollar per year. Since I just wanted to try things out, I chose the cheaper option. So I can tell you only about how it works for Android, but assume similar steps need to be taken for iOS.
To publish your app, you need to upload an .apk file (Android Package) in the Play Console together with some extra information such as some general information, screenshots and a description. In order to get this APK to the Play Store, you need to perform several steps:
Good luck!
See also the documentation here: https://docs.mendix.com/howto/mobile/publishing-a-mendix-hybrid-mobile-app-in-mobile-app-stores
Regards,
Ronald