Make sketches for your new cot. Decide how big you need it to be as a first step. The bigger the cot, the more comfortable you will be, but the bulkier and heavier it will be while you carry it. Your sketches need to include a method for folding and transporting the cot.
Cut your aluminum. You can use wood, but it will be heavier and less-durable. The aluminum needs to fit your sketches exactly or the plan you created won't work. The two sides need to be longer than the person sleeping in the cot or your feet and head will dangle.
Solder the aluminum elbow couplings to the long poles. The holes on these need to face each other, because you will need to be able to place a shorter piece of aluminum between them to make the cot tight.
Make your legs. The recommended method of allowing your cot to fold up is to make the legs "X" across one another in a way that will allow them to collapse in and fold the entire cot. To do this, make one leg full length and cut the other segment down into two segments. Use a bracket to connect the two smaller pieces, with the bigger piece in the middle, in a way that allows the entire thing to swivel and move freely. Then, attach the two, long pieces of aluminum to the X you've just made, and you have the frame to your cot. To make it taught, you'll need removable ends that you attach into place manually.
Make it into a bunk. To make this simple cot usable as a bunk, you'll need to make the cot described above twice. But, to add stability to the center, attach poles on each side in the center. You need to make this pole removable or the bunk won't be able to fold.
Test the bunk before you take it camping. There's only one thing worse than realizing that your home-made cot doesn't work: realizing it on a camping trip. Test it out thoroughly before you take it into the woods.