Squat question

God I hope I dont get reemed for asking this but here it goes. I have a problem with pivoting my shoulder,eg.trying to hold the bar across my traps to squat. It gets extremely tight and I just cant move it back. Anyone have any idea what this could be? It doesnt hurt at all in any other position, and it does not hurt in a resting state. But if I put my arm in a 90 angle and try to pivot up past my head I cannot do it. I also feel pain when trying to do this.