For a registered domain, the authoritative nameservers are defined by the domain holder and given to the registrar to be passed up to the nameservers for the next higher level domain. For example, the nameservers for stackoverflow.com are chosen by SO's admins, given to the domain registrar Donuts, who then passes them to VeriSign (who run the com domain) so that the nameservers for com can return them in response to any queries.

For subdomains of that domain, the nameservers queried first are those defined for that domain, as above. If the subdomain has NS records, instead of whatever type was asked for, then the nameservers shown in those NS records must be returned instead, as they are authoriative. This is indeed a delegation. The client then must query those servers.

This is pretty much exactly what your second image shows.

You can run dig with the +trace option to see this work with any DNS query you care to make.