Immagino che ti sia dimenticato di assegnargli l'id...
codice:
var tuoInput = document.createElement("input");
tuoInput.setAttribute("id", "input1");