I started thinking, how am I going to create such distance between the images so that they fit my div perfectly? I remembered some time ago making a menu just like this, except it only used text, no images.
I used the word-spacing tag in CSS to create such distance, and it worked fine. So my solution was to use between my images:
Yes, don't use use HTML to get a visual (presentational) result. Instead, use something like margin or padding. We need to see your page to be sure, but a way to go about this is to make an unordered list (<ul>) with each <li> containing an image. Set the <li>s to display: inline block and text-align: center. That will center the items inside the div. Then add left-right margins to get them the right distance apart.