The ID vs. Key definition is true across all objects inside of SFMC - Data Extensions, Send Definitions, SQL Queries, Triggered Send Definitions, etc.
The ID is a GUID that is created by SFMC when an object is created. It is read-only and will never be changed, until the object is deleted. This is usually what is used internally or when using 3rd party API to integrate with SFMC. The reason is that this identifier will never change, so if someone goes into your account and accidently changes the name or key or location something, it will have no effect on the functionality of your call.
The Key is a user-defined string that can hold up to 36 characters (I believe you can edit some of them up to 200 characters, but honestly, 36 is best practice and recommended). This string is then read/write permission, allowing you to adjust it at any time you want, whether via the UI, API or Scripting language (AMPscript, SSJS). The purpose of the external key is for a friendly identifier for any querying or filtering you do via API or Scripting language. E.g. for Lookup functions, Core functions, etc. As well as using Retrieve Requests inside API or filters, etc. The risk with using these user-defined and editable identifiers is if it is changed, you will need to update all calls/functions that utilize the old identifier to correctly associate it with the new one, or the calls will break.
SubscriberID vs. SubscriberKey
ContactKey vs. ContactID vs. SubscriberKey
What is the difference between Primary Key Contact ID, Contact Key, Subscriber Key and Subscriber ID?