You can have a job that is a private arrangement between two people. In other words, you are not working for a business or organisation. This could include babysitting, teaching someone to play the piano or coaching them at tennis. Discrimination law does not apply to this sort of work.
The thinking behind it is that equal opportunity law protects equal participation in public life, not in private life. Hiring someone to work for you privately, and not for a business that you run, is considered part of private life. This probably reflects a value position that people should be allowed to discriminate in their own homes if they want to.
Criminal law certainly does apply in people’s homes, because part of its purpose is to protect people’s safety.
With discrimination law, its purpose is to stop prejudice from standing in the way of a person’s opportunity to take part in wider society. Lawmakers decided it should not apply in all areas of life but laws can be changed any time if enough people want it.