why 'if (object == null)' is true?

I want to differentiate when an object is instantiated.
But when I try this, it does not differentiate what was instantiated and what was not, because it always returns null.

    MyItem item;
	void Start () {

		// Here returned "is null". OK
		if (item == null) {
			Debug.Log("is null");
		}else{
			Debug.Log("not is null");
		}

		item = new MyItem ();

		// But here returned "is null".
		if (item == null) {
			Debug.Log("is null");
		}else{
			Debug.Log("not is null");
		}

	}

To use the line :

item = new MyItem();

Your class must not inherit from Monobehaviour. If, for some reasons, you still need it as a Monobehaviour, you can do this :

item = new GameObject("objectName").AddComponent<MyItem>();

Note that this will instantiate a new game object in the scene, named objectName, with MyItem script attached. You will be able to use item as intended afterward.

Another alternative would be to add the script to the current gameObject (if any)

item = gameObject.AddComponent<MyItem>();