create insert function

data will be inserted