The health code includes personal information, such as name, ID number, and cell phone number, etc. If you lend your health code without knowing whether or not you're infected, and if you do get infected, you'll be able to spread the disease by using the borrowed code, and you'll be penalized by the law.
You can contact Alipay's health code customer service, explain the situation and provide the corresponding Alipay account and user information, in order to feedback to the back-end verification. You can also call the police directly to let them handle the situation.