creating file properly