Chrome didn't get its marketshare out of thin air either. It paid other software to be bundled just like malware apps, and automatically configured itself to be the default browser.
It also prominently advertised itself on the Google home page, which would probably cost many many billions of dollars if a non-Google browser wanted to do the same thing. On top of that, if you used another modern browser like Firefox, Google websites had popups that you should upgrade your outdated browser to Chrome.
Once Chrome on desktop was popular, then came the "oopses". [1] Accidentally breaking Google websites on non-Chrome browsers left and right.
After Android became popular, it's not hard to guess which browser they shipped by default on millions of devices. Device manufacturers weren't allowed to remove Chrome if they wanted to have working Google Play Services and access to the Google Play Store. I think recently in the EU manufacturers are allowed to remove Chrome and keep Play Services because Google got fined 4 billion euros.
[1]: https://www.zdnet.com/article/former-mozilla-exec-google-has...