If you have navigation bar and you need custom back button, you can add it like this:
let button = UIBarButtonItem(title: "Back Title", style: UIBarButtonItemStyle.Plain, target: self, action: #selector(someMethod))
self.navigationItem.leftBarButtonItem = button
And in your selector you can dismiss your current viewController or call some other back method
EDIT
If you need some custom animation with standart push transition style you can do next:
For example create viewController in storyboard with SecondViewController
id
At your transition action method make some like this:
func showSecondViewController() {
guard navigationController != nil else {
return
}
guard let secondViewController = storyboard?.instantiateViewControllerWithIdentifier("SecondViewController") else {
return
}
navigationController!.pushViewController(secondViewController, animated: false)
UIView.transitionWithView(navigationController!.view, duration: 1, options: .TransitionCrossDissolve, animations: nil, completion: nil)
}