create a plain GameObject through script

this is what i have at the mo
public class FakeCollider : MonoBehaviour {

    public GameObject  m_realcolliderObject;
    private GameObject m_triggerObject;

    void Start()
    {
        Instantiate(m_triggerObject, m_realcolliderObject.transform.position, m_realcolliderObject.transform.rotation);

        m_triggerObject.gameObject.AddComponent<BoxCollider>();
        m_triggerObject.collider.isTrigger = true;
        m_triggerObject.GetComponent<BoxCollider>().size   = m_realcolliderObject.GetComponent<BoxCollider>().size;
        m_triggerObject.GetComponent<BoxCollider>().center = m_realcolliderObject.GetComponent<BoxCollider>().center;

    }

    Vector3 m_position =  new Vector3(0,-100,0);
	// Update is called once per frame
	void Update () 
    {
        m_triggerObject.transform.rotation = m_realcolliderObject.transform.rotation;
        //m_position
	    m_position.x = transform.position.x;
        m_position.z = transform.position.z;
        m_position.y = 20;
        m_triggerObject.transform.position = m_position;
        
	}
}

the idea is that i create a plain gameobject athe the same place as the other game object , create a collider , assign the same size and postion of the collider , make it a trigger and offset it each update to position.y = -100;

it gives a null refernce for the Instanceate.

i have tryed

m_realcolliderObject.AddComponent<GameObject>();

but it does not like this eaither

any ideas please?

This creates an empty GameObject:

GameObject yourName = new GameObject();

take a look to the documentation:

the instantiate function returns a gameobject.
the first parameter to the instantiate function considers a prefab, not the gameobject, that hold the newly instantiated gameobject in your class.

more correct would be:

m_triggerObject = Instantiate("YourPrefab", m_realcolliderObject.transform.position, m_realcolliderObject.transform.rotation);