Even on the largest ships, the captain’s quarters would never be called “spacious.” For this reason, a captain’s bed was a small affair. For your modern version, a twin size mattress is a perfect fit. You will want the bed to take up as little floorspace as possible.
If you want to make your captain’s bed feel authentic, a twin size mattress has another benefit. Much like a modern daybed, the captain’s bed had to serve as a seating area; a twin size bed suits this purpose much more easily than a larger mattress would. You might want to give your twin captain’s bed a slightly higher footboard (to match the headboard) and add a back side to serve as a backrest for some cushions and extra pillows. This way, your bed will almost feel like an seating alcove--very cozy.
Captain’s beds were the original storage beds. With so little room aboard ship, the area under the captain’s bed was filled with drawers. These were much more useful than open shelves or cabinets, especially when high waves could rise up at any moment.
Make the drawers in different sizes, with some being smaller than others; this is how a real captain’s bed would be built, so smaller objects would not be tossed around when sailing rough seas. You can line them up in two rows, with the smaller drawers on top; or you might put a couple of large drawers at the head and foot, with a group of smaller drawers in between them.
A captain’s bed is all about the details. Although a captain’s bed would never be built as a bunk bed, it would often have a raised lip along the front edge; this would act the way a guard rail on an upper bunk does, to keep the captain from being tossed out of bed by a sudden roll of the ship. You do not have to make a high lip, or even run it the full length of the bed; a common modern adaptation of this idea adds a short raised apron at both the head and foot of the bed, leaving the middle of the side lower for easy entry and exit.
Remember that nautical details are what really make a captain’s bed stand out. Use brass hardware on the drawers, perhaps some brass angle pieces on the corners to resemble reinforcements on a treasure chest, and surround the bed with furniture that has a nautical theme – a bedside table that looks like a treasure chest, for example.