It also could be that OP's body language was giving an air of impatience, and was making them uncomfortable. We don't know.Maybe that person offering suggestions suffers from social anxiety and is trying to "break out of their shell". Maybe they're on the spectrum and struggling to fit into society. Maybe they're just really lonely and looking for any kind of social interaction, no matter how small.
Point is we really can't read anyone's minds so if something like this happens to me out of the blue I just try to be polite. This lousy world needs more kindness in it and I try to do my part, even if it's small
What OP needs to realize is that their reaction is atypical. While the reaction could be considered valid given certain personal circumstances, they need to realize that this is their own internalization of the situation, and that the person offering them guidance is not specifically "out to get them". When they realize this and accept it, they can manage their reaction better, because going through life like this is unpleasant and unhealthy.