An object of a class is null, and I don't understand how to fix it

Hello. Now my question will probably seem borderline retarded to mor experienced users but I’m still very new to Unity and C#. My problem is that I currently have two separate scripts attached to the Player. One which handles his health/death and one for everything else. Now in the script for everything else (called PlayerScript) I do this:

    public PlayerHealth playerHealth;

To my understanding that should create an object of the class PlayerHealth called “playerHealth”. Now playerHealth is apparently null. I don’t get any NullReference Exception errors but nothing happens when the player collides with an enemy. Here’s the code for that:

    void OnTriggerEnter2D(Collider2D other)
    {
        if (other.gameObject.tag == "Enemy" || other.gameObject.tag == "EnemyBullet") //|| other.gameObject.tag )
        {
            playerHealth.TakeDamage(20);
        }
     }

I checked by using a break point and playerHealth is null here. So what am I doing wrong? If you need to see more of the code I’ll provide it but I didn’t actually write the PlayerScript, my team member wrote it.

Your variable playerHealth is not initialised. With the statement

 public PlayerHealth playerHealth;

you are telling the compiler “I want to reserve a public variable of type PlayerHealth in memory.”. But that object is just reserved, it’s not “filled” with anything, so in your case, it’s null.
You want to have a reference to your other script on the GameObject. This reference needs to be established first. Put the following code in your Start() function:

void Start() {
playerHealth = GetComponent<PlayerHealth>();
}

This way, a reference to your other script is “established” and saved in playerHealth.