Custom fields are defined and created directly in the product.
Go to the backoffice, "Products" > "View" > and select the product to which you want to add custom fields. Look for the option "custom fields" and add as many fields as you need (with their name and associated value).
Finally, from the doofinder app, activate the option to index custom fields.