Can I upload an existing world from Pocket Edition to make a realms server? I have a huge castle map which I really want to play from my Mac instead of on the PE edition.
Minecraft on Mac/PC is almost completely different from MCPE file-wise. Sorry, but it is not possible.
It is possible, through the use of MCCToolchest PE. Using this you can convert the world from Bedrock to Java, and thus play it on your Mac.
Yes, You can upload worlds to a realms server on PE, however you will be unable to play on that realms server on PC/Mac. You could install Windows10 Edition if you have a windows10 PC and use that to play on your realm. Hope that's helpful:)
Here's the problem, Minecraft on the Mac is Java Edition. And although this may not mean anything to you, Minecraft on mobile is Bedrock Edition, with different redstone physics and different commands. So, no, you can't transfer worlds from Mac to PE or PE to Mac.