How to create a custom object