Is getting some nutritions and energy out of consumed food.
It happen in different steps in corresponding part of digestion tract/intestine. Rests of food and some digestive secretions form excrement/feces/stool.
Unneeded stuff (+) is excreted also by urine, sweat and breath.
In the intestine the are plenty of microorganisms.
They play important role in Digestion, but cen also be harmful.
Important is balanced microflora that can be suported by Diet and some Supplements.