Creating entities with ids