Some times they are planned cities and are usually only one architect (or one lord) designs it. They were often built where there was already a village, or at a place of historical importance. They were sometimes also built where people bought and sold things a lot (for example where trading routes crossed).