That's pretty cool! Perhaps genetic or innate memory is how he knew what to do? Sort of like dogs eating grass when they are sick?
(says https://www.worldwildlife.org/stories/5-remarkable-animal-mo...)
A shame they're critically endangered.
I'm not sure about where these orangutans live, but my guess would be that, if it is not a thing the orangutans knew, centuries of living alongside humans... they probably picked up a thing or two. They're quite smart creatures.