Internal issues. Could be a variety of issues: bursits and tendonitis, rotator cuff injury, tears of a tendon, joint injury, etc
you evaluation will include a history and physical; imaging like x-ray, ultrasound, MRI to define the problem. The treatment can be physical therapy, injections etc.
Unstable shoulder. Shoulder is a very mobile but unstable joint, it could be due to lax ligaments or mild anatomical variations, physical therapy under supervision of a qualified physician will be first step after initial imaging like xray and MRI has been done.