initialize tags input like
$('.div-tag').tagsinput({
allowDuplicates: false,
itemValue: 'id', // this will be used to set id of tag
itemText: 'label' // this will be used to set text of tag
});
To add dynamic tag
$('.div-tag').tagsinput('add', { id: 'tag id', label: 'tag lable' });
That's it;