How can I switch view controllers with code swift xcode : 
    let SecondViewController = 
    self.storyboard?.instantiateViewController(withIdentifier: 
    "SecondViewController") as! SecondViewController
        
    self.navigationController?.pushViewController(SecondViewController, 
    animated: true)
    
For some reason this doesn't work. Any ideas? Thanks!