Telling someone the encryption key is being compelled to act as a witness against yourself, which the 5th amendment provides protection against (if used).
No it's not. The information you provide (the password) is not admitted as evidence in the trial. It's more like being compelled to act as a confidential informant against yourself.
There's no prospect of this being used to bring about a wrongful conviction through coercing a confession.
The whole point of strong encryption is to prevent adversaries (including forensic scientists) from extracting any information without possession of the key.
If the key involves a password that you, a human, have memorized in your squishy pink organ, it's privileged under the Fifth Amendment. (This hasn't been tested in court yet, of course. There's no precedent to fall back on.)
Telling someone the encryption key is being compelled to act as a witness against yourself, which the 5th amendment provides protection against (if used).