Satan was one of God's angels in heaven. In fact he was an angel of a very high order. We know that unlike God, Satan had a beginning, and he will have an end. In Isaiah 14:12 it reads, "How you have fallen from heaven, O star of the morning, son of the dawn! You have been cut down to the earth, you have weakened the nations!" This verse indicates that Satan indeed was an angel in the heavens, but was punished for his wickedness. Genesis 1:31-2:1 informs us that "God saw all that He had made, and behold, it was very good. And there was evening and there was morning, the sixth day. Thus the heavens and the earth were completed, and all their hosts." This is important because this means that Satan was originally created good. In fact, it was said about Satan that "You were blameless in your ways from the day you were created until unrighteousness was found in you.” (Ezekiel 28:15)
What did Satan do? Isaiah 14:13 reads, "But you said in your heart, 'I will ascend to heaven; I will raise my throne above the stars of God, and I will sit on the mount of assembly in the recesses of the north. I will ascend above the heights of the clouds; I will make myself like the Most High.'" Essentially, Satan wanted more power. He had selfish ambitions and wanted to be just as powerful as God, if not more. We know, however, that "For everyone who exalts himself will be humbled, and he who humbles himself will be exalted" (Luke 14:11). Satan is a perfect example of the first half of this scripture; his pride and ambition cost him his position in heaven and God had to revoke the privilege Satan initially had in the Heavens with God. While ambition is necessary for the Lord's people, it's important to note that it isn't a selfish ambition, yearning for greatness or prominence. Rather, it's a humble, loving ambition to serve the Lord and his people. This kind of ambition is the kind talked about in the second half of the scripture, and Jesus is our wonderful example that we must strive to model ourselves after.
Finally, Ezekiel 28 is a good chapter to read to understand who Satan was, when he was created, and the reason he was cast out of Heaven. While the following verses were directed at the king of Tyrus, the king symbolized Satan which is evident by the passage. For instance, verse 13 states that "You were in Eden, the garden of God." We know that it was Satan that was in the Garden of Eden, who tempted Adam and Eve, the first account where Satan outright defied God's wishes. Therefore, we can safely deduce that the following verses also describe Satan. Verse 14 states that "You were on the holy mountain of God" and in verse 15 that "You were blameless in your ways from the day you were created until unrighteousness was found in you." Satan was an "anointed cherub" (verse 14), who "had the seal of perfection, full of wisdom and perfect in beauty" (verse 13). As the "Son of Dawn", he was one of God's earliest creations. He had a beginning, and he will have an end because "you corrupted your wisdom by reason of your splendor" (verse 17). While we consider Satan to be the prince of this world today, God promises to Satan in verse 19, "you will cease to be forever". In Isaiah 14:15 it is said "Nevertheless you will be thrust down to Sheol, To the recesses of the pit", which would be Satan's ultimate, final destruction.