The machine-specific instruction is composed of a name, operands, and kinds (or flags) that denote additional information about the instruction.
The meaning of the name and operands is specific to a particular machine and encoding (see Insn.encoding). The meaning of the instruction kinds is more or less universal.
code insn returns an integer code, that is bijective with instruction opcode. It might not be the actual opcode, it may also change between different backends, and different versions of the same backend.
name insn returns a textual representation of the instruction name. It might be the mnemonics, or a name, specific to a backend. The name is guaranteed to biject with the opcode (and thus to code).