Compressing an image means re-encoding it: decode the original to pixels, then encode back out at the quality you choose. That quality setting governs how much visually insignificant information the encoder is allowed to discard; so compression here is lossy, and a different thing from the fully reversible compression in a ZIP file.
How much you save depends far more on content than on the original file size. Photographs, gradients and noisy scenes have a lot of redundancy to give up. Flat colour, screenshots and line art already have low entropy, so they shrink very little; and lossy encoding may add visible artefacts around the text edges. Those images are better left as PNG, or moved to lossless WebP.
When the goal is page load speed, changing format usually beats tuning quality: at matching perceived quality WebP is typically about thirty percent smaller than JPG, and AVIF smaller again. The tool keeps the original format by default and lets you switch the output to WebP when you want that trade.