Absolutely!
Zerkers fall into the infantry unit even though they are considered a specialty unit. This means that swords are going to be your primary defense against any zerkers.
Trebuchets are going to fall into the defensive category. They are very slow and therefore not ideal to move around from city to city, so once you build them and shift them around, it's best to leave them sit. I typically will build anywhere from 40 - 100 of these guys in my treb villages and I'll move them around to cover my offensive cities to prevent ram nukes from completely destroying those walls. I'm not sure what category they fall in to since they are neither mounted units, infantry, nor archers. I think they fall into their own category or the get defaulted to the archer category since they are ranged. I haven't really had a lot of chances to experiment with them too much.
Rams are unique in the fact that they are they only siege weapon in the game that doesn't require a boatload of them to bring down a building level. 400 rams is over kill on rams, but it's almost guaranteed to bring down the wall to 0 when they hit. I believe this defaults to the infantry group since if we're assuming it isn't in a group of its own.
Cats are useful in both offense and defense. Offensively you don't really want a lot of them since they are much more effective in smaller waves. For example, I sent 3 of them on an attack with a full nuke earlier this week and I expected them to just die and to my surprise, they brought down the building I targeted by a whole level. Defensively you're probably only going to build 100 of them (which is how many I build for offense as well, ironically). The reason people build them as defense is because they are fantastic at taking out archer type units. I believe these fall into the archer category if we're assuming they're not in their own.
Spears, Swords, Archers, Heavy Cav, Trebs, and Cats can be used defensively. I don't recommend going defensive in your first village because your troops will just die on enemy walls when you try and take them and barb nobling is very frowned upon (unless you're in Omerta or something).
Axes, Light Cav, Mounted Archers, Rams, Cats, and Berserkers are all considered offensive. Ideally you'll want to find a mix that works for you in your area. There is no perfect nuke that will kill everything. It's likely you'll have to send a combination of a ram nuke, followed by a horse nuke, followed by an infantry nuke. Or some mix of that.
Despite what you may have heard, it is absolutely never a good idea to mix offensive and defensive troops in the same village. You can support an offensive village with defensive troops and move your defensive troops out to prevent the enemy killing them, but never build both types in the same village. Hybrid villages are only going to get you sent to the rim. They aren't good at anything. Attacking, defending, or even farming.