UIBezierPath and UIView coordinates

I have the following: p1 is the red dot. graph is the white UIView canvas.

p1.center = CGPoint(x: 50, y: 100)
p1.backgroundColor = UIColor.red
graph.addSubview(p1)

let path = UIBezierPath()
path.move(to: CGPoint(x: 0, y: 500))
path.addQuadCurve(to: CGPoint(x: 100, y: 500), controlPoint: p1.center)

shapeLayer.path = path.cgPath
shapeLayer.strokeColor = UIColor.orange.cgColor
shapeLayer.lineWidth = 2.0
graph.layer.addSublayer(shapeLayer)

As you can see, I attempted to draw the path to curve at the center of p1, but that's clearly not the case here. What's going on? Is it because they're using different coordinate systems?

enter image description here