Yes, to test for string equality you need to use equals() or equalsIgnoreCase(). There are more fundamental problems with what you have written there though and it will not compile. Re-examine the basic structure of 'if' statement blocks.
There are some fundamental problems with your program structure. You seem to be doing password validation in 'Password.java' itself and that too in the main method which isn't such a good idea. Plus your 'Record.java' file is never used.
A simple way would be to create a new file 'Main.java' whose main method would create instances of the 'Password' and 'Record' type as per required by your program logic. Just make sure to keep nothing in main method except instance creation and method invocation i.e. maximum abstraction.
I would recommend you to read some good book and tutorials which teach Java as well as OO programming in general.