Is this an example of a group? Let G be a set having more than one element and let $a\ast b=a$ for all $a,b$ in $G$. Is $G$ a group under this operation?


*

*I think $\ast$ is associative since $(a\ast b)\ast c=a$ and $a\ast (b\ast c)=a$.

*I also think there exists an $e$ in $G$ such that $a\ast e=a$ and $e\ast a=a$ for all $a$ in $G$, because you can just choose $e=a$ and this seems to work. 

*What is the inverse of $a$? Can the inverse of $a$ just be $a$? Is this allowed? Does this work?

 A: No, you don’t have an identity. There is no single element $e\in G$ such that $e*a=a*e=a$ for all $a\in G$. Suppose that we actually had such an $e$. By hypothesis there is at least one $a\in G$ such that $a\ne e$. But then $e*a=e\ne a$, and $e$ isn’t an identity element after all.
You’ve shown that for each $a\in G$ there is some $x\in G$ such that $x*a=a*x=a$, namely $x=a$, but this isn’t what it means to have an identity. For that you need a single element, $e$, that works for all $a\in G$. In logical notation, you’ve proved that 
$$\forall a\in G\exists e\in G(a*e=e*a=a)\;,\tag{1}$$
but the statement that $e$ is a group identity is
$$\exists e\in G\forall a\in G(a*e=e*a=a)\;,\tag{2}$$
with the quantifiers in the opposite order. In $(1)$ the $a$ is specified first, and you get to pick a different $e$ for each $a$. In $(2)$ the $e$ must be specified first, and then it has to work for all choices of $a$.
And of course if you have no identity, it’s meaningless to ask for inverses.
A: $ab=a$, and $ba=b$.  Which of these two is the identity?
(If there is only one element, then this is indeed a group, and then $a=b$ in the situation above and there's no conflict.)
A: No, since non-identity elements have no inverse. If $ab=e$ then $a=e$.
A: If you set $e=a$, does there exist more than one distinct element in your group? If $a,b\in G$ and $a\ne b$, then $e\ast b = e = a \ne b$. So it is not the case that $e\ast b = b$, which means $e$ is not an identity element. (Informal proof by contradiction.)
A: No, such structure is not a group. In literature it is often called right quasigroup.
It has no identity element (hence it is not a right loop), but all of its elements are right identities: we deduce it from the definition $a\ast b=a$.
How nobody said this before? ;)
