Contrary to popular belief, the filter’s job is not solely to remove large bits of fish waste; it’s to chemically cleanse the water of the highly toxic waste chemicals that fish produce as part of their daily biological state. (Ammonia, which is extremely harmful to fish, is produced when fish excrete and breathe.)
In nature, these harmful chemicals rarely become a problem because the climate and the continuous flow of water remove them. However, in our enclosed environments these harmful chemicals are dangerous killers.
It can help to think of filters as a house for bacteria. These bacteria live on the media inside the filter. Different types of bacteria consume and convert the fish’s harmful waste chemicals into less harmful substances, which you (the fishkeeper) can then remove via a small water change. This process is known as the nitrogen cycle.