I am going to provide my insight to hopefully serve as a complement to existing answer and comments because I think this is an interesting question.
In addition to perfectly valid methods already mentioned, an additional approach for H2S management in aquarium could be also controlling amount of foods with a significant load of sulfur-containing amino acids (methionine and cysteine) being fed.
Methionine is an essential amino acid, so one shouldn't attempt eliminating it completely from fish diet because that would ultimately lead to fatal malnutrition.
On the other hand one should keep in mind that sulfur-containing amino acids are used as substrates for hydrogen sulfide production in anaerobic conditions - and for that reason, make sure that such foods aren't being carelessly fed in excess. Stagnant, fine, deep substrate mixed with decomposing chunks of uneaten, high in sulfur-containing amino acids food in a warm, tropical aquarium is in this context a perfect environment for H2S production.
For example, some fish foods are sold in an "ovo" version, which means an egg-based or egg-enriched version with strenghtening properties meant for feeding young and growing up fish - and egg proteins are exceptionally high in sulfur-containing amino acids, which is also simultaneously the exact reason why the disagreeable odor of H2S is associated with the odor of rotten eggs. My approach for the H2S management in the tank would be in essence making sure that foods like that are used in carefully controlled amounts, or not used at all if it's not really needed.
Also some specific plant foods like cabbage, broccoli, cauliflower and Brussels sprouts are high in sulfur-containing amino acids so please be careful and stay informed if you plan on feeding them to your fish.
Generally in this context it would be helpful to always carefully study and accurately determine the amino acid nutritional profile of any type of food being fed, but in practice it could often prove to be unreliable or tedious.
And something about hydrogen sulfide itself: yes, this is a naturally occuring compound and it's used in miniscule amounts as a signaling molecule in living organisms - for this reason there exists a metabolic pathway for neutralizing miniscule amounts of it. But it becomes easily overwhelmed with relatively small amounts of H2S, and H2S interferes with cellular respiration, hence it's high toxicity - which is actually comparable to the toxicity of carbon monoxide and hydrogen cyanide.
Stirring the substrate, either performed manually or by snails as mentioned in others' answer/comments is also an efficient method of H2S management - but actually it's main goal is not releasing H2S from the substrate but rather mixing oxygen-rich water into it - oxygen presence enables aerobic metabolism in substrate inhabiting bacteria and thus disables H2S production, which occurs in anaerobic conditions.
In addition to snails, there also exists an interesting genus of fish Acanthopsis choirorhynchus which is apparently named commonly as horseface loach. It is known for its behavior of being noticeably mobile and also completely burrowing itself in the substrate, being exceptionally efficient in frequently stirring it and thus preventing anaerobic conditions arising. For these reasons, in my native language it is also somewhat errorneously named as what could be roughly translated as "mud-eater" or "slime-eater". It could be a wise choice to include this fish if your tank has appriopriate type of substrate for it. However, keep in mind that this fish is so aggressive in it's mobility that it tends to uproot plants.
My general source was Wikipedia.