How to rotate encryption key for Realm DB

If we need to rotate the encryption key for realm DB. How can I rotate it without losing the existing data?