add create_position function to memstore