Can “whose” refer to things?
Yes. “A house whose roof leaks” is standard English and has been for centuries. The alternative, “a house the roof of which leaks”, is clumsy. Style guides including Merriam-Webster’s usage notes accept “whose” for inanimate nouns.
Catch it automatically
The grammar checker flags common mix-ups like this one by looking at the words around them, and the sentence checker can explain any sentence you’re unsure about.