Its totally normal for him to do that when he thinks he's being attacked, or to defend himself in a new environment.....I wouldn't worry....he should be fine now....I had a porcupine puffer and he only puffed up when I put him in the tank and took him out.
Hope that helps!
Later!