Checking if a single object's trigger is entered out of a group of identical objects?

In my game I have a group of objects with the same tag and a trigger collider. When the player collides with any of these objects, a parameter within the player is changed and that works fine. (This is done in a script attached to the player).

Now in a script attached to each object, I want to have it that if the player collides with that object, a parameter of that single object is changed.

The problem is when I use OnTriggerEnter, I cannot specify whether the collision is between the player and the specific object. I cannot check if the colliding gameobject has the object’s tag cuz all the objects in this group have the same tag. And when I check if the colliding object has the ‘player’ tag, the function is called when the player collides with any object, not just the specific object the script is attached to.

I have searched so long for an answer, so I hope someone here can help me.
Here’s some of the code simplified.

// Function in Player Script
private void OnTriggerEnter2D(Collider2D collision)
{
    if (collision.gameObject.tag == "Object")
    {
        object = true;
    }
}

// Function in Object Script
private void OnTriggerEnter2D(Collider2D collision)
{
    if (collision.gameObject.tag == "Player")
    {
        player = true;
    }
}

If I understand you correctly, you want to check if the collided object has ObjectScript.

private void OnTriggerEnter2D(Collider2D collision)
{
     if (collision.gameObject.tag == "Player")
     {
         ObjectScript script = collision.gameObject.GetComponent<ObjectScript>();
         if (script) //This will only work if the object have "ObjectScript" script attached to it.
         {
              //Do whatever you want here
         }
     }
}