1. An image processing apparatus for processing an image including a plurality of areas which include a foreground area and a background area, comprising: a modification part configured to instruct modification of a portion of the image which is erroneously divided as a result of dividing predetermined image data into the foreground area being an extraction target and the background area being an out-of-extraction target; a model creation part configured to create a foreground model of the foreground area and a background model of the background area which are modified, based on first pixel values of a predetermined line segment where the modification is instructed and second pixel values of the foreground area and the background area which are divided; and a division part configured to divide the image data into the foreground area and the background area by using the foreground model and the background model which are created by the model creation part.