How does a CDN improve performance and how would you configure one?

Technical