You are trying to append pointer to struct to the slice of Product not slice of *Product. Quick solution would be to change
var products []Product
into
var products []*Product
solved How can I change the package type when calling a method? [closed]