Remove and Replace Api Keys

I want to change the values of all api keys in my serverless.yml but it seems it’s impossible to do so. so I want to delete them and create new ones with new values.

However, I couldn’t remove them from serverless.yml so I headed over to api gateway console and removed them manually. now when I deploy it gives me this error:

Invalid API Key identifier specified

Then I opened the console again, and recreated the key. still the same error.
Any way to solve this?