Grammar checkers cannot know when the passive voice is appropriate or not. In many cases, they can't even identify the passive correctly. You should always treat such advice skeptically.
Even worse, simple-minded style guides like The Elements of Style have convinced many writers and educators that the passive voice is always bad, when of course that is false. So advice from native speakers about the passive voice cannot always be trusted.
You seem to have identified the appropriate guideline. If the agent of solve is irrelevant to the context or cannot be known, then the passive might be the best choice.
Furthermore, if the topic of the passage is problem, then a structure that makes problem the grammatical subject is probably a good choice.