In most cases (Im generalising) Someone code their pages on their own computer. Then they upload it to a server to be accessed through a URL. e.g www.my-site.com/page.html
When coding your HTML pages you most likely wrote it via your editor and tested it by double clickign the file and viewing it through yor browser.
Your 'local machine' is your computer. the 'remote machine' is the server.
However if you want to test your PHP on your local machine you need to ahve Apache/PHP running. In order for the PHP program to know that it needs to parse a file it needs to be accessed through a browser.
If you merely double click the browser just attempts tor ead from the file. It can't understand PHP so just outputs it as if it were HTML.
But if you have the PHP in your root folder and type ina URL the browser attempts to download the file. Your local PHP server resides on that URL (my example was http://127.0.0.1) and when the browser request it it will recall the file. The PHP finds its file extension is .php and so will parse it and then send it to the browser as HTML.
I HOPE that explains it. I'm quite bad at explaining what I mean.