Why is employee record viewable by Head of department

Hello All. I created a department with employees, and these employees report to the Head of the depart. At the moment, the head of the department is able to view the record of these people, but I don’t want the head of the depart to have access to those employee records, only the Head of the HR department should have that right. How can I disable the head of the department from having access to those employee records? Currently running the latest version of ERPnext.

Go to the Users → User Permissions and remove the user permission on Employee for the HOD Employee Number.