Prokaryote cells don’t have lysosomes, so the first lysosomes probably evolved about the same time as the other pieces of eukaryote cells. That was about two billion years ago. Like the vacuoles and the Golgi bodies and the other parts of a cell, lysosomes (LIE-sew-somes (like HOMES)) are small round bubbles of lipid membrane.
These digestive molecules would be dangerous if they were floating around loose in the cytoplasm. They might start digesting the nucleus or the cell membrane by accident! So the cells survived better if they evolved to pinch off bits of their cell membrane to surround these dangerous molecules. The lysosomes keep the molecules away from the rest of the cell.
Lysosomes take in whole vacuoles that are floating around in the cytoplasm and break them up into smaller pieces that will be easier for the mitochondria to turn into energy. For example, lysosomes break up captured viruses or bacteria (germs) that have gotten inside the cell and are threatening to destroy it. So if your lysosomes weren’t working well, you would get sick more often, and it would be harder for you to get better. One serious disease that is caused by a problem with your lysosomes is Tay-Sachs Disease.