The four Marys. Mary Beaton (or Bethune), Mary Livingston (or Leuson), Mary Fleming (or Flemyng), and Mary Seaton (or Seyton); called the “Queen's Marys,” that is, the ladies of the same age as Mary, afterwards Queen of Scots, and her companions. Mary Carmichael was not one of the four, although introduced in the well-known ballad.
Yestreen the queen had four Marys, This night she'll hae but three: There was Mary Beaton, and Mary Seaton, Mary Carmichael, and me.
Source: Dictionary of Phrase and Fable, E. Cobham Brewer, 1894