File file = new File(args[0]);

what this line of code actually mean?

as long as it is taking place in the main method it is creating a reference to a file using a name provided on the command line (the first argument after the classname in the java command).