The existence of both good and evil spirit beings is a prominent doctrine in LDS theology.
Spirits are intelligent, self-existent, organized matter and are governed by eternal laws.
Moreover, all living things had a pre-earthly spirit existence. Joseph Smith taught that elements were not created or made, but can be organized into a spirit being. This spirit, intelligence, or light has always existed, being coeternal with God. All men and women lived as personal, individual spirit children with God in a premortal life before they were born into physical bodies. Likewise, one's personal, individual spirit existence extends beyond the death of the mortal body.