The advantage of using a country-specific domain in SEO terms is that your site may rank slightly better for searches from that specific country. It won't make it rank any worse for searches outside the specific country though.
Spelling an English word using a foreign domain extension won't improve your ranking for that word either, although it might improve the ranking for the word stem before the dot (e.g. 'branch' in the case of 'branch.es').
Search engines work by determining language from the html language attribute and/or by auto detection, not by the domain extension alone.