Kidd buried the stolen treasure, and the devil presides over it to make sure nobody retrieves the money.
At the beginning of the short story, Irving writes that on top of a high ridge with a few scattered oak trees just a few miles from Boston, Captain Kidd buried a massive amount of treasure under one of the trees. William Kidd was an actual pirate, who supposedly buried treasure in the Caribbean before he was arrested and hanged in 1701 by the British authorities. Irving writes that Kidd chose the high bluff as the ideal location to hide his buried treasure because the inlet allowed for easy access by boat and the high ridge provided a prime lookout. Irving also writes that the devil presided during the hiding of the money and took it under his guardianship. As the story goes, Kidd never returned to Boston to retrieve his treasure and was hanged for piracy.