To be honest, Grammarly's AI detector looks for patterns in writing, such as predictability, phrasing, and sentence structure, to determine whether or not material may be AI-generated. However, it's not 100% accurate, so I would use it as a helpful pointer rather than a definitive judgement.