Pictures help, I had this same issue many year ago with a Norinco AR. Likely the castle nut wasn't staked properly that started this entire ordeal.
As for the retainer pin, some pictures would help see if there's an alighnment issue or if it's installed improperly.
If I understand you correctly, im guessing either the buffer tube(receiver extension) is threaded in too far, or not far enough.
If you're a competent individual with some basic tools, you should be able to resolve it, if not I'd recommend calling the place of purchase and filing a warranty claim.