File is not a file on your system. new File("MyFile.txt") is creating a new File Object from where you can call various Methods, to create a file on the system, such as .createNewFile(). If your using Sierra & Bates
JAVA 5 see page 431, for more details. The example given there is:
Its a simple method for giving feedback on the existence of files, so;