It's a random fault that both S8 models and Note8 also had, my first note 8 had it and I ended up having to send it in for warranty repair as none of the fixes or factory reset would cure it
Never have had a moisture message on my Note 8 in about a year's steady use. Perhaps it's because I live in Colorado, a very dry state or out West where humidity is rarely a factor.