Default Push APP when sharing WIFI hotspot, how does it work


I am an Electronic Engineer and I am new to Android programming and I need to know how it works when a phone access a free wifi hotspot and an app is being downloaded (web page opens and allows you to download an App) to the phone when trying to access the internet ?

Anyone knows this and can share or share good links to info, thanks.

In the end I would like to setup an ANDROID phone and a PC as the wifi hotspot so they can download an app to a phone when connected via the hotspot (which can be another phone or a PC, both actually but not at the same time).

Regards Peter