If you only have member(X, [X|_]).
and you execute this query: member(will, [will,anna]).
You will get true.
because according to your rule, the X, which is will, is the head of the list.
But if you only have that rule and you execute member(anna, [will,anna]).
, you will get false because anna is not the head of your list.
Let's see your second rule.
You create your program as member(X, [_|Y]) :- member(X,Y).
You execute the query member(will, [anna, eddie, pat, will, marjorie, donna]).
And this is what Prolog sees:
take the list and remove the head. Do the same for the rest of the list, until the tail is empty.
You get false.
because there aren't any elements left in your list.
Your problem is that you don't check if X is a member of your list. You could as well rename that rule as removehead(X,[_|Y]):-removehead(X,Y).