"Нужно" agrees with the object that's needed ("что"), not the person who needs it.
I answered "what does this girl need". The computer accepted it, but assured me that "that girl" was also correct, and in fact I see from the above that "that girl" is the preferred answer. If этот, тот, эта can mean either "this" or "that", when is the use of это, то, та obligatory? And,, since это seems to be quite generally used, when is the use of этот obligatory?
You'll probably find olimo's guide to это helpful. https://www.duolingo.com/comment/11536858
The one thing it doesn't explain is the difference between этот and тот. Fortunately that's fairly simple, этот translates as "this" and тот as "that", but тот isn't generally used except when contrasting this and that, so in most cases you'll use a form of этот.
If "Что" is the subject, doesn't that make "that girl" the object, and thus accusative? I don't see why it should be the dative case.
этой девочке is the indirect object, so it's in the dative case: something like "what is necessary to the girl?" This is similar to how the dative is often used when there is no subject at all (subjectless, or impersonal expressions) - there's a video on those here: https://youtu.be/PR5iOYybOdc
I think of нужно as "is needed", so the sentence in a more literal translation is "What is needed by that girl?"
Why not "девочки"? I know dat. requires -е but what about the spelling rule -- always -и after -к
The spelling rule doesn't mean that nothing else can come after к. It just says that ы can never come after к, it's и everywhere you would expect ы.