I'll use them in of three instances:
1. At a chokepoint as said above.
2. A ring of forts around my capital. If I play in a setting with constant war and aggressive AI, having a ring of forts around your capital basically makes it impossible to take, but this only happens in a specific style of gameplay.
3. This is my most often contender, along my frontier. If I'm playing against a really powerful enemy military, every tile that borders him I'll build a fort, basically making a massive wall that's really hard to break through. Then, once I go on the counter attack, I destroy the forts and replace with other improvements and then build forts on the new frontlines. This only works if you have an army of workers to support your conquests, but it's highly effective as:
A. If your advance is beaten back, you have a strong barrier to halt the enemy.
B. If you have to halt, you aren't in a vulnerable position.
C. It constantly gives you a military edge.
D. It looks REALLY cool.