refactor attachement model
implement remove function of attachement