Well, we just had morning play time, and he did much better than last night.
When I first brought him out of the cage, I put him down in the litter box, and he wanted to bolt immediately. But I pet him for a second until he settled down. Once he realized he was in a friendly place, he sat calmly, munched a little hay, and peed in the box like he should! He still pooped on the carpet a little once he got out and started wandering, but nowhere near as much as last night. Mostly, he used the box this time, so I think he's learning.
And as I said, he was starting to munch hay, so I think he's got that figured out now, too. I also cut a baby carrot into 8 little pieces for him and used them as bribes for good behavior. I lured him back into the litter box with them twice, I lured him out from under the couch once, and I used them to calm him down when I put him back in his "cage" (cardboard box) when play time was over. The fact that I have to pick him up to put him in and out of the "cage" is a little distressing for him, so getting a treat seems to help. Once I get him a real cage, that won't be such a big issue, though I'm still likely to use treats to convince him to go in it when I want him to.
Also, I've decided to name him Flash. This seems like a good fit, since he's red and runs around really fast.