Autobiographical note: My mother taught me the definition of metaphor using the Alfred Noyes poem The Highwayman, the second line of which is, “the moon was a ghostly galleon cast upon cloudy seas.” I have no idea why that was what she used, but I rather suspect that’s the way she learned it.
Highwaymen were robbers who operated (mostly) on the British Isles* between the Elizabethan era and the early 19th century. Specifically, highwaymen rode on horseback; thieves on foot (or those who robbed pedestrians) were called footpads. Traditionally, men on horseback waited in wooded areas on the main roads leading out of London as this offered both a place to hide and a variety of marks to choose from. In England, the penalty for highway robbery was death by hanging. The last recorded incident of highway robbery occurred in 1831 and while the burgeoning railway business is given as a reason for the decline, the industry, such as it was, had been declining since the middle of the 18th century. It is more likely that the decline was a result of the expansion of the turnpike system with manned and gated toll roads, as well as the increasing use of banknotes rather than gold coinage as currency.**
Essentially, Robin Hood, whether he was real or is just legend, was a highwayman.
*There were also highwaymen in France and Hungary. And, although the term is specific, the action is not. In the American west, they were called road agents; in Australia, they were known as bushrangers.