name is a team name. So you need to instantiate a new Team object and set its name :
public static void main(String[] args) {
System.out.println("Enter name team");
Scanner tn = new Scanner(System.in);
Team team = new Team();
team.name = tn.nextLine();
}