Hello,
Because all your photos are different width. Use all the image same width before uploading them to your media library. Then it will allow you to build nice grid.
Regards