You don't know in principle whether this is the full Hilbert space only from the Hamiltonian. It might be that there is an arbitrary (possibly infinite, or even continuous) amount of states with vanishing energy. A quantum system is only well defined, if you give its Hamiltonian and its Hilbert space.
If you are only given this Hamiltonian, it might be informally implied that the Hilbert space is spanned by $|1\rangle$ and $|2\rangle$, but there is no formal way of proving this. But, if you know that the Hilbert space is two-dimensional and that $|1\rangle$ and $|2\rangle$ are linearly independent, then they necessarily span the entire space.
Also, note that your last sentence is not quite correct. The eigenvalues of the Hamiltonian are the possible results of energy measurements, not the possible energies of states.
For nearly every state of the system it doesn't make sense to talk about its energy. Only the eigenstates of the Hamiltonian have definite energy. To superpositions of those eigenstates you can only assign energy expectation values which must not conincide with one of the eigenvalues.