Well... most animals dont have the consciousness of themselves... if im not mistaken, the only ones who have a consciouness of theirselves are the apes and the dolphins...
I think the ego appears with the reflexion of our awareness... like, every percieving being has awareness of its surroundings, as they see, hear, and so.
But we humans have awareness of our awareness. We percieve that we percieve. I dont just see... i see, and im aware that i see. So, im aware of my own awareness.
But if i know that i see, then i may ask "who is seing"? And i will answer "me". I think the notion of a self starts there.
Its only what i can answer... it may even be wrong, but its in what i believe. And, for me, it makes some sense.