Make sure in the course, assign certificate/badge should be enabled and certificate template or certificate badge image should be set. Only then this functionality will work. Students can check the earned certificates or badges in “Achievements” Menu.