How can I find a hash with leading zeros
You're missing multiple parts here. If that's your complete code, you don't seem to be adding a nonce to your preimage at all. You will need to generate a nonce, add it to the preimage, and test the corresponding digest against your acceptance criteria. To that end, you probably want to use a while loop that continues rolling random nonces and testing digests until one has the correct prefix. In the success case, it should output the relevant nonce.

You will also need to make sure that you use the same method of combining the nonce and your name as the exercise's test framework.