Yes this is perfectly fine. My person preference is to change this to the simple present tense rather than the conditional:
Many metals are damaged when exposed to water, but diamond is not.
The simple present is used to indicate something that is a general truth.
(Edit) Many native speakers are uncomfortable with my example sentence, first because the use of "diamond" rather than "diamonds" seems to break the style rule of parallelism. While I agree the syntax is a little strange, in this context it's fine because "diamond" is the (uncountable) material, while "diamonds" are the cut gemstones made from the material. Consider:
The foolish man sunk his entire inheritance into a diamond mine. (not a diamonds mine).
"Metal", similarly, refers to various (uncountable) substances, some of which can be damaged by water (iron, etc.) and some which can't (gold, etc.). So comparing one set of substances to another substance is perfectly parallel.
Some native speakers also feel this sentence implies diamond is a metal. Ordinarily, if forced to make this comparison) I would include some kind of disclaimer to avoid any confusion:
Many metals are damaged by water, but diamond (which is not a metal) is not.
In addition, a friend pointed out this sentence unnecessarily uses the passive voice, which I could avoid by changing the verb:
Many metals corrode/oxidize in water, but diamond does not.
Finally: I don't understand why OP is comparing metals to diamond, which is a crystal. Chemically they are different enough that few would expect them to share similar physical properties. But since that's off-topic in a forum on English Language, I'll let it slide.