The first definition
Is being aware of your own existence.
Which is often tested by showing an animal itself in a mirror.
If it realises it sees itself and not another animal it's self-aware.
The other definition
Is being aware of your consciousness and accountability.
(Your actions and possible outcomes).
You know if you steal your brother's sweets, he'll get angry.
We can't tell what animals are thinking from their actions, so their level of self-awareness is open to debate.