Does taking keys off of a MacBook keyboard void warranty
Solution 1:
Assuming you signed the AppleCare plan on the US, this is what the legal document states:
4. What is not Covered?
(ii) Damage caused by (…) (b) accident, abuse, misuse, liquid contact, fire, earthquake or other external cause, (c) operating the Covered Equipment outside the permitted or intended uses described by the manufacturer, or (d) service (including upgrades and expansions) performed by anyone who is not a representative of Apple or an Apple Authorized Service Provider (“AASP”);
I'm not a lawyer, but abuse and misuse may be applied to removing keys.
You may get away with it if you present it as an "upgrade", and you are an Apple Authorized Service Provider :)
Solution 2:
Generally you can do anything to your Apple device as long as the Apple Genius/tech cant see evidence of what was done. Which means that If popping off key caps and then putting them back on leaves no trace you are likely safe.
And I mean no trace. You would be surprised what an Apple genius/technician will find that you never noticed.
And third party replacements totally count as evidence of "tampering." So if you put a 3rd party SSD (or RAM, or whatever) in the Mac, put the Apple branded part back in before you take it in to Apple as they will take it out and say they can't and won't support non-Apple parts.