Fields hold the object's data. Methods are the actions. A class can also contain a main method so you can run it directly while you are learning. Later, main usually lives in a small starter class.
new allocates the object and runs a constructor. If you do not write a constructor, Java supplies one with no parameters, but only when you have not written any constructor yourself.
Example
new Course() uses the default constructor. report reads the two fields and prints them.
public class Course {
String title = "Java";
int hours = 40;
void report() {
System.out.println(title + " " + hours + "h");
}
public static void main(String[] args) {
Course c = new Course();
c.report();
}
}