Borders used to be how you designated your territory prior to the Gloomrot update. They still have a use for creating balconies and railings on higher castle floors. They must be connected to the Castle Heart or other floor / border tiles. You can build within them and around their edges.
Players were unable to build tiles within 2 squares of other player territories by default. (prior to update)
Border tiles and floors are all 10x10 units, and walls and fences are 10 units long.