This solution is based on the hint given by Johannes Kloos in the comments above.
Let $R$ be a unital ring, with unit element $1_R$, and let $R'$ be an integral domain (which is not a priori assumed to be unital). Suppose we have a nonzero homomorphism of (nonunital) rings $\phi:R\to R'$. We want to prove that $R'$ is actually unital, with unit element $\phi(1_R)$.
First, we have the following equality:
$$\phi(1_R)=\phi(1_R1_R)=\phi(1_R)\phi(1_R).$$
Hence, we see that $\phi(1_R)$ is an idempotent of $R'$. Now, since $\phi$ is nonzero, $\phi(1_R)\neq 0$. Therefore, for any element $x\in R'$, we have
$$\phi(1_R)x=(\phi(1_R))^2x \Longrightarrow x=\phi(1_R)x,$$
and similarly, we have $x=x\phi(1_R)$. Therefore, we conclude that $\phi(1_R)$ is a unit element of the ring $R'$.
There are several definitions running around, confusing people like you when you read from different sources. For some of them the answer is "Yes", for some the answer is "no".
Some definitions of unital rings wouldn't consider $\{0\}$ a ring at all, since they require that the multiplicative identity is distinct from the additive one. Disregarding that, a subring is a subring by virtue of the inclusion homomorphism, and some sources require that ring homomorphisms preserve the multiplicative identity. In that case, $\{0\}$ is all by itself without any homomorphisms of any kind to any other ring, so it's not included in any other ring either. However, that's usually unporoblematic since these two definitions often come together (so if your definition of homomorphisms would make $\{0\}$ sit alone, your definition of ring would make it not a ring at all).
So, if we let $\{0\}$ be a ring, and we don't require homomorphisms to treat the multiplicative identity with any more care than any other element, then yes, you can include $\{0\}$ into bigger rings and have it be a subring. The same way you can include $\Bbb Z$ as the first component of $\Bbb Z\times \Bbb Z$, for instance.
When I first learned about rings, I prefered the more relaxed requirements, because I thought they made life easier. These days I prefer the stricter requirements because I feel that they make life easier (knowing that the image of $1$ is $1$, and not just any idempotent element really helps some arguments, for instance).
Note that if your definition of rings requires a multiplicative identity to exist in any ring, then you will most likely be in the stricter domain (requiring $1$ to exist means it is nice if we require homomorphisms to respect it). The more relaxed domain typically doesn't require a multiplicative identity to exist in rings (although, of course, some rings happen to have one).
Best Answer
Many authors take the existence of $1$ as part of the definition of a ring. In fact, I would disagree with Alessandro's comment and claim that most authors take the existence of $1$ to be part of the definition of a ring. There is another object, often called a rng (pronounced "rung"), which is defined by taking all the axioms that define a ring except you don't require there to be a $1$.
Rng's are useful in of themselves, for example functions with compact support over a non-compact space do not form a ring, they form a rng. But there is also a theorem that states that every rng is isomorphic to an ideal in some ring. So studying rings and their ideals is sufficient, and this is why it is so popular to include the existence of $1$ as one of the axioms of a ring.
So to summarize, there isn't really a reason why it's necessary for rings to have a $1$, it certainly does not follow from the other axioms. It's just a choice of terminology: Do you say rings have a $1$ and if they don't have a $1$ call them rngs, or do you say rings don't need a $1$ and when they do have it call them rings with unity?