A scammer offers you a member account that already has a membership. You may give them an item for it, or they may offer it for free. If you put rare items on that account, the scammer will later transfer those rares to their account and/or change the password so you can't access the account. Either way, they end up with your rares.
A scammer offers you a member account (or membership) in exchange for rare items. You give them your rares, and then they never give you the membership/account.
A scammer says that they need your AJ user and password in order to put the membership on your account. Instead of giving you membership, they steal your items. They may give you membership to lead you on, and then steal the items that you get as a member.
How to avoid this scam
Method 1: If someone gives you a member account, enjoy the benefits of being a member while you can, but keep your rares on a different account. It's more than likely that the person who gave it to you will take it back, expecting to steal whatever you put on there.
Method 2: The only way to avoid getting scammed is to not give rares for membership. It's very likely that you'll get scammed if you go first. Even if you successfully get the membership, the person who gave it to you could use Method 1 to take it back and steal the items you put on that account.
Method 3: If someone requires your password in order to give you membership, it's probably a scam. If you want to risk it, don't give them the user and password to your main; make a spare account. If you get membership, don't put rare items on that account. Change your password right after.
Exchanging rares is not a recommended way to get a membership, since the chance of getting scammed is high, and it's against the AJ rules. You could get banned from doing this.