ok, so I was looking for some items to help me with the Madame X battle(I've made my goal to beat it, and I will do it), and some of them were held by wild pokemon.
so I was using an article in bulbapedia to help me, after a couple items of running way, frisking and thiefing I found how the items held by wild pokemon mechanic works in this game:
If its a pokemon from gen 7 or an alolan form, it will have the chance to hold the item as it would in Sun and Moon. Ex: Chargabug can hold a cell battery and A-rattata can hold a pecha berry
If its a pokemon from gen 6 or prior that could hold an item in ORAS, it would hold the item as it would in ORAS. Ex: Trubbish can hold a black sludge, despite in Sun and Moon that being impossible, and spearow can't hold a sharp beak, despite in Sun and Moon that being possible
And if the pokemon couldn't hold an item in ORAS, it would hold according to the earliest circumstance of it being able to. Ex: Pansage had a change to hold a Oran Berry in gen 5, but not in ORAS, however, when its encountered, it will have the chance to hold it. Same goes to poochy/mightyena, for exemple, which had a chance to hold a pecha berry in BW/BW2, but not in gen 6
Hope I helped! And I apologize if this has been made before, I looked for something similar in this forum and didn't find anything