How lovely that your older boy wants to share! If you have access to a trundle bed or toddler bed that might take up less space at first. My boys had a bunk bed (the older one got the top) and it definitely helped on space. Also, you can put a reading light up there for your older son -- if it won't bother your younger son -- so he can read or do a quiet activity while the little one sleeps. It might be helpful to not make the shared room your younger son's play area, reducing the chance of him messing up his older brother's things. Once serious homework sets in for your 10 y/o it might be more difficult to share a room. (My older son did not want to share a room after age 13 as his way of unwinding for bed, plus needing a quiet time for schoolwork and reading, did not match the pace of his younger brother.)
I think it's awesome that your 10 yr old is looking forward to sharing! Go with it!! I'd get bunk beds, but your 3 yr old may still need to be close to you so you might want to set up a crib mattress or something on the floor in your room next to your bed or at the foot of the bed... or maybe a loft bed for the boys w/a single on the top and a double down below so they can sleep together...? However you decide to arrange sleep start the transition now! So everyone is in the groove by the time baby arrives.