To serve a purpose is to be useful for something. Every bracket on that shelf is there because it holds something up.
The article changes the meaning, which is the thing to watch. Serve a purpose means it is useful; serve its purpose means it did the job it was made for; and serve no purpose is the dismissal, which is where the phrase turns up most. Serves you right is a different idiom altogether, and to what purpose is the rhetorical question a leading article asks.
1phraseserve a purposeTo be useful for something.
“Every part on that shelf must serve a purpose.”
serve a purpose is a usefulness.
Practised in Common Word Pairs