Odds are when you made it to the Altar of the Sunne, you didn't expect to literally be thrown into battle with Dusk Mane Necrozma. And honestly, it might seem a little intimidating at first with being Level 50 and having had its stats bolstered with its new transformation. But don't fret, as Dusk Mane Necrozma, at least in this battle, isn't as difficult of a Pokemon to defeat.
For one, it might continuously use its move Morning Sun instead of attacking for some weird reason. If this happens, just keep hitting with Super Effective Dark Type and Ground Type Attacks, and it will be down before you know it. If you aren't so lucky, continue to go for its weak points with those Dark Type, Ground Type, and Fire Type Attacks. Using the move Taunt will also prevent it from regaining its HP with Morning Sun, which is nice if you have a Pokemon with such a move. Using Special Moves are also recommend over Physical Moves, since Dusk Mane Necrozma is weaker in this given area.
If worst comes to worst, it will take you a few attempts to defeat Dusk Mane Necrozma. This is nothing in the grand scheme of things, as you should always save before entering the Altar of the Sunne in case you do need to reset without losing any ground. The real challenge comes after defeating Necrozma in this given form.