How the Mob Builder Works
Only the fields you set end up in the NBT — leave anything blank and the mob spawns with vanilla defaults. Health writes both Health and the max_health attribute together; equipment uses the 1.21.5 equipment map in current format and the HandItems/ArmorItems lists in legacy format; entity-specific modules (baby, color, cat variant, villager profession) appear only for entities that actually support them.
Example — current 26.x format
/summon minecraft:zombie ~ ~ ~ {CustomName:{text:'Boss Bob'},Health:100.0,attributes:[{id:'minecraft:max_health',base:100.0},{id:'minecraft:attack_damage',base:8.0}],equipment:{mainhand:{id:'minecraft:diamond_sword',count:1}},PersistenceRequired:1b}
Example — legacy 1.13–1.21.4 format
/summon minecraft:zombie ~ ~ ~ {CustomName:'"Boss Bob"',Health:100.0,Attributes:[{Name:"minecraft:generic.max_health",Base:100.0}],HandItems:[{id:"minecraft:diamond_sword",Count:1b},{}],PersistenceRequired:1b}