That is not guaranteed to work. You could rename the existing index.php index2.php and add a new index.php, but that could affect links back to the home page. Also, more importantly, it could be easily bypassed by directly calling the index2.php (or any other page on the site!).
To enforce login is a more complex issue, you really need to do it as a PHP include file (or script) controlled by POST parameters and a lookup to a database of user IDs and passwords. You could write it yourself, if you have PHP experience or the time to learn, but no doubt there are copious login templates available if you search for them. By the way, if the site is written in a CMS, you'd best use a template specifically written for that CMS. Otherwise you could have untold problems with code conflicts!