Yes, in general you can use "couldn't have" to make an assumption about the past. Your example works and here's another: "He couldn't have left yet because his car keys are on the table."
Just for reference, In American English, your second example should be
He could have gotten stuck in traffic.
Chris reminded me got is find in British English