You don't need a special licence to marry under age just permission from a parent or guardian. The marriage register itself should state one of the party was under age and the banns (or licence if they had married by licence) should give details of who was giving the permission. Under age people if they could get away with it, often didn't admit they were under age because of the extra hassle, so this alone doesn't prove James was indeed over 21 but if he had been under age it would have helped confirm the age given on the censuses.
Other parishes did not open their doors to unmarried mothers giving birth in their area so the question isn't why did Elizabeth go to Gilling to give birth to Mary. She would have to have been established there and have settlement, otherwise Gilling would have moved her back to Leyburn. They wouldn't have wanted an illegitimate child and mother charged to their rates if they could have helped it. Try checking the poor law for any evidence of Elizabeth and Mary - settlement/removal and or a bastardy order.
James does not just give Spennithorne as his place of birth - he only gives that once, Harmby twice and 'Throstle Nest' once - which is a very specific place. I believe from Googling there is a Throstle Nest farm at Harmby.
"HARMBY, in the parish of Spennithorne wapentake of Hang West & liberty of Richmondshire; ¾ mile NW. of Spennithorne, 1 mile E. of Leyburn. Population, 194."
If you search on the censuses for any other Spences giving Throstle Nest as a birthplace you find one on the 1871 census.
RG10 4743 folio 126
North Riding of Yorkshire Lunatic Asylum Clifton Yorkshire .
Richd Spence 60 Throstle Nest Patient Widower Shoemaker
Back tracking him on censuses you get
1861 census RG9 3544 folio 98
North and East Riding of Yorkshire Lunatic Asylum Clifton Yorkshire
Richard Spence 51 East Witton, Yorkshire, Patient Widower Shoemaker
1851 census HO107 2379 folio 155
West Witton Yorkshire
Richard Spence 47 Harmby, Yorkshire, Head Widower Master Shoemaker
Elizabeth Spence 17 West Witton, Yorkshire, Daughter Housekeeper
Hauxwell Spence 8 West Witton, Yorkshire, Son
Susanna Spence 5 West Witton, Yorkshire, Daughter
Jackson Spence 1 West Witton, Yorkshire, Son
1841 census HO107 1254/14 folio 8 page 11
West Witton Yorkshire
Richard Spencer 30 Yorkshire Shoemaker
Catharine Spencer 30 Yorkshire
Elizabeth Spencer 7 Yorkshire
John Spencer 6 Yorkshire
William Spencer 4 Yorkshire
Richard Spencer 1 Yorkshire
From the IGI
RICHARD SPENCE
CATHERINE JACKSON
Marriage: About 14 MAY 1833 West Witton, Yorkshire
And of course rather tantalising the earlier two Spennithorne baptisms are
JAMES SPENCE
Christening: 31 DEC 1809 Spennithorne, Yorkshire
Father: JOHN SPENCE
Mother: ALICE
RICHARD SPENCE
Christening: 13 AUG 1809 Spennithorne, Yorkshire
Father: JOHN SPENCE
Mother: ALICE
Regards
Valda