On line on the ancestry site is Tennessee the Volunteer State 17691923: Volume 2
on page 102 it states:
In April, 1798, John Coffee and his mother settled on the Cumberland River, a few miles above Nashville, near Andrew Jackson and the Donelsons and married Mary Donelson, a niece of Mrs. Jackson. A strong friendship was formed between [p.102] him and Andrew Jackson which continued unimpaired until Jackson's death. They formed a partnership in mercantile business which was not successful, and Coffee withdrew in 1807 and devoted himself to surveying.
When he married Mary Donelson in 1809, her father, Captain John Donelson gave her a farm on Stone's River in Rutherford county, near Old Jefferson, and they lived there throughout his military career and until they went to Alabama, near Florence, in 1819. While living near Old Jefferson, he was elected county court clerk of Rutherford County.
Hope this helps explain the relationship of the two wives.