Yes, Moss can detect Chegg. If the solution is provided anywhere on the Chegg website, Moss can detect it and flag it as plagiarism. To stop that from happening, you should always find the original source of the information and cite it appropriately. If the citation is done correctly, it won’t get flagged anymore.