This is a known issue and the current workaround is to base64 encode your variable. Please see: Problems with multiline environment variable - #33 by shaunmulligan for details.
I will add your request to our tracker to make sure your use case is noted. To help me understand better, can you explain why you need a newline in your RSA key? As far as I know, an RSA key doesn’t typically have a newline in it.