Sie haben den/einen Schlüssel = They/You have the/a key. (singular)
Sie haben die/-- Schlüssel = They/You have the/-- keys. (plural)
So in this sentence "Schlüssel" represents the indefinite plural of some keys. Therefore, the only valid translation is "They/You have keys."
You is take as formal here.
No native English speaker would say "you have key". If there's only one key involved, you must have "the key" or "a key".
I have keys to the building. /or/ I have a key to the building.
The German word "der Schlüssel" does not have a separate plural marker, so "die Schlüssel" is only identified by the "the" word in the sentence.
It is confusing! 'Sie' can be she, they, or formal you (capitalised). 'der Schlüssel' is the singular, and 'die Schlüssel' is the plural, so that can be confusing as well because the word doesn't change, just the article. This happens with some masculine and neuter nouns (das Fenster; die Fenster).
It might have counted the extra -n, although technically it shouldn’t because Schlüsseln is the dative plural form instead of accusative plural which you need here (haben wants an accusative object). Maybe Duolingo just doesn’t know about that form because it happens not to appear in any sentence in its database? Not sure. In any case, it should definitely be Schlüssel, without -n.
Yes. This happens sometimes with masculine or neuter nouns, that the plural form does not change. The article is what gives it away: der Schlüssel - die Schlüssel ; das Fenster - die Fenster. Feminine nouns will always have a change in the plural, since both are marked by the article 'die'.