The main purpose of this study is to determine the efficacy and safety of baricitinib for the treatment of severe or very severe alopecia areata (hair loss) in children from 6 years to less than 18 years of age. The study is divided into 4 periods, a 5-week Screening period, a 36-week Double-Blind Treatment Period, an approximately 2-year Long-term Extension Period, and a 4-week Post-treatment Follow-up period.