I am confused with the definition of ordinals: "A set $a$ is an ordinal if it is transitive and totally ordered by $\in$." Then an ordinal is a set but we also know that all elements of ordinals are ordinals themselves.
If we take $\alpha=\{x,\{x\}\}$ then $\alpha$ is a transitive set and totally ordered by $\in$ so it is an ordinal. But $x\in\alpha$ so $x$ is an ordinal but $x$ is not a set and ordinals are sets.
Can someone please fill in this gap in my understanding?