how to keep cloning even the real one has destroy c#

i try to make infinite object with clone as enemies. But when the real object has been destroyed, cloning has stop. I try this code to clone the object.

using UnityEngine;
using System.Collections;

public class Spawner : MonoBehaviour {

	public GameObject enemy;

	void Start(){
		StartCoroutine (EnemySpawn ());
	}

	IEnumerator EnemySpawn(){
		while(true) 
		{
			Instantiate (enemy, transform.position, Quaternion.identity );	
			yield return new WaitForSeconds(3f);

		} 
	}
}

Instead of pointing already spawned enemy object to your “enemy” variable you should create a Prefab and set it to “enemy” variable. Also this code shouldn’t be on the enemy itself, of course, unless you want to stop their spawn when all of them die.