The lemma states that "Let R be a commutative ring with unit element whose only ideals are (0) and R itself. Then R is a field." My question is that what if we don't assume the ring has unit element? Can we deduce that the ring has unit element? If we can, please give me some hint how to show it? If we cannot, then please give an example of a ring without unit element whose only ideals are (0) and R itself?
Use the additive group of integers module $p$ a prime, and use trivial multiplication (every product is zero.)
I leave it as an exercise for you as to why it is relevant to your question.