object oriented – How to change the java program

This is my code

package ro.upt.cm.provocare;

import java.util.HashSet;

public class Provocare {

public static void main(String() args) {

    Person p1 = new Person("Alex", 23, 1.5);
    Person p2 = new Person("Alex");
    
    
    HashSet<Person> persons = new HashSet<Person>();
    persons.add(p1);
    persons.add(p2);
    persons.add(p1);
    
    System.out.println("Number of persons in collection: " +persons.size());
    System.out.println("The person collection contains the object: " +persons.contains(new Person("Alex")) );
    
    System.out.println(persons);
}

}

And this is my output:
Number of persons in collection: 2
The person collection contains the object: false
(Person (age=23, name=Alex, high=1.5), Person (age=0, name=Alex, high=0.0))

How do I change the program so that I’ll have the following output:
Number of persons in collection:1 The person collection contains the object:true
(Person (name: Alex, age:23, heigh: 1.50))