Yes, you most certainly can if you have experience building outdoor furniture and fencing. Ultimately, a DIY catio can be just as large as you want it to be, and you can make it fit precisely in your house.
The catio must have adequate fencing on the entire surface. There should be no interruptions to the fencing because the cat could try to escape through there and end up getting hurt.
This is the simplest type of catio available, but your cat is guaranteed to love it. It is box-shaped and made out of catio fencing with a waterproof roof.