【Updated: 】
Since you can use the same save data even after changing devices, you can continue to use rubies and other items from your old device on your new device.
However, you can only use obtained and purchased rubies on devices with the same OS.
For that reason, if you wish to change to a device with a different OS, be aware that you will not be able to use any rubies from the previous device.
Note: You will still be able to use them on the original OS.