Yes they do. Every living thing does. Even plants do in their own way.
I keep Fish, shrimp, snails, and isopods and they all do too. Fish and shrimp actually poop quite a lot, especially the latter. I don’t think I could ever eat shrimp after seeing how many turds those things produce.
Do trees poop?
https://www.todayifoundout.com/index.php/2017/07/do-trees-poop/
I started quoting relevant parts but there’s so many different ways they get rid of waste that it got silly.
In a nutshell (lol): sap, leaves, petals, fruit, dead wood inside the tree, and root excretions are all kind of tree poop in their own ways.
There are face mites that also don’t poop. Their lifes are so short that simple holding it in till they’re dead is easier
Incorporated septic tank