Your browser opens each image, draws it onto an invisible canvas and writes it out again in the format you chose. JPEG and WebP are lossy: the quality value tells the encoder how much detail it may throw away, so a lower number gives a smaller file and a softer picture. Because the file is re-encoded, a lower number is not a guarantee. Some images, such as screenshots and flat graphics, can come out the same size or bigger.
PNG works differently. A browser's PNG encoder is lossless, so there is no quality setting to turn down and the slider is switched off for PNG output. The ways to make a PNG smaller here are to lower the Max dimension, which removes pixels, or to change the output format to WebP or JPEG. This tool does not reduce the number of colours.
Max dimension limits the longer side of the image and keeps the proportions. Images that are already smaller than the limit are left at their size, never enlarged. Photos that were taken rotated are drawn upright, so they do not come out sideways.
After each run the tool compares the new file size with the original and tells you plainly whether the result is smaller, about the same, or larger. A difference of up to 0.5% of the original size is reported as about the same.