The only way to get 256GB RAM in an iMac Pro is to buy a custom configuration from Apple

The recent addition of an option to configure an iMac Pro with up to 256GB of memory may be the only time users get to add that much RAM to their Mac, with internal documentation reportedly suggesting it won’t be possible to upgrade versions with lesser memory capacities to that level after purchase.

Source:: Apple Insider