Yes, it is possible.
First, save everything you might need from the hdd and ssd.
To make it simpler, install Windows first. If asked, select custom install/setup, and you can select where to install windows. You need to delete every partition, so you can only see the unformatted and unpartitoned drives.
You will now half the storage on each drive, by creating a partition (a 125GB partition on the ssd, and a 500gb partition on the hdd), and format them. Leave the free space for ubuntu unpartitioned, and carry on installing Windows.
After it is installed, install ubuntu. Select custom installation aswell, and you can format the space for linux here.
After linux is installed, you may want to start gparted and label each partition with a name, as there will be 5 partition seen by ubuntu, and shown in the file explorer. Identify them according to
On the ssd:
The partition for windows (125GB, ntfs filesystem)
The boot partition for windows (100MB, ntsf)
And the partition for Ubuntu (~125GB, has ext4 filesystem)
(Note that there may be a separate partition as the children of the 500GB Ubuntu partition, with "Swap" as the filesystem, but you can ignore this, because it wont show up normally in the file browser
On the hdd:
The windows partition for games (500GB, ntfs filesystem)
And Ubuntu partition for games (500GB, ext4 filesystem)
After labeling them, mount them (if they werent mounted by default) and open the file explorer, to see if they show up by the labels you gave them