The word demesne seems to just be an alternative spelling of the rather more logically-spelt domain. I’m wondering how this strange spelling came about? Even taking into account its given etymology from the Old French demein, how did the letter “s” get in there?
OED has this in its etymology (this is an extract):
The Anglo-Norman spelling demesne of the law-books, and 17th cent. legal antiquaries, was partly merely graphic (the quiescence of original s before a consonant leading to the insertion of a non-etymological s to indicate a long vowel), as in mesne = Old French meien, meen, mean, modern French moyen; partly perhaps influenced by association with mesne itself, in ‘mesne lord’, or with mesnie < mansionāta house, household establishment. Demesne land was apparently viewed by some as terra mansionatica, land attached to the mansion or supporting the owner and his household. Perhaps also Bracton’s words [below] gave the notion that the word has some connection with mensa.
[c1250 Bracton iv. iii. ix. §5 Est autem Dominicum, quod quis habet ad mensam suam & proprie, sicut sunt Bordlands Anglice. Item dicitur Dominicum Villenagium, quod traditur villanis, quod quis tempestivè & intempestivè sumere possit pro voluntate sua & revocare.]
So: a long vowel (the second e) was indicated in spelling by inserting an s.
OED does use the word “Perhaps”, but it does seem to me to be a bit far-fetched to think that people confused mensa and mesne.