Placement of 在 in the sentence
Normally  the 'relative phrase that indicates location (在+ location)' is always placed before the verb


Example:

他在北京旅遊 cannot be changed to 他旅遊在北京

他在北京探親 cannot be changed to 他探親在北京

他在北京被捕 cannot be changed to 他被捕在北京


  Why is 他出生在北京 and 他在北京出生 both correct?



You can treat the sentence as [topic + comment] structure


['他出生' (his birth)]  is the topic ['在北京' (was in Beijing)] is the comment

In other words, "他出生在北京" is short form of "他的出生 是在北京"


or you can treat it as simple [S+V+O] structure


['他' is the subject] ['在北京' is the relative phrase] ['出生' is the verb] (no object)