It happens because you have different aspect ration for images uploaded to your products. If you want to make all products inline you need to upload all images with the same proportion. Otherwise, you can enable hard crop in WooCommerce -> Settings -> Products -> Display and regenerate all thumbnails. But it will crop your images and in some cases, it may look incorrect.