They bake the cookies flat, and then quickly fold them around the paper while they are still hot. After a few minutes the cookies harden, so they have to work quickly. I tried to make fortune cookies once, with personalized fortunes for the person receiving the cookies. Alas, it was a failure.