nodeMCU station vs AP

The ESP8266 can be access point and station - and do this at the same time.

To the web server it doesn't matter at all how the connection is made. A request comes in and is processed. So indeed if you connect to the same ESP8266 through its access point, or through its external IP, you see the same page.

IP addresses get assigned the moment the WiFi connection is made, not when code is uploaded or so.