Hi,
Check out this example: GitHub - bpmn-io/bpmn-js-example-custom-elements: An example of how to support custom elements in bpmn-js while ensuring BPMN 2.0 compatibility.
Note that BPMN allows custom shapes only in the artifacts group, so what you create may deviate from the standard.