Is this a bug or what is wrong?

I was trying to solve this puzzle but my white pawn always promoted to queen which is wrong!! also tried different engine and it’s doing the same move!!

please check the attached images below

What is the correct move then?

Hmm it looks like you mirrored the position I guess?

Try this fen 8/5pB1/8/2p2p1R/4rPk1/6P1/5K1P/8 w - - 0 1 Rh4#

I told before 30 second not enough for find good moves in some positions I can give many examples
try tis FEN 2b5/1p1p1p2/1PpPkP2/K1PR3p/4P3/4P2P/4P3/8 w - - 0 1
NCM showing Rg5 mate in 14 move right answer is below

1. Rf5 h4
2. Rf4 Ke5
3. Kb4 Ke6
4. Kc3 Ke5
5. Kd2 Ke6
6. Ke1 Ke5
7. Kf2 Ke6
8. Kf3 Ke5
9. Kg4 Ke6
10. Kg5 Ke5
11. Rxh4 Ke6
12. Rh8 Ke5
13. Re8#

Try this FEN 8/1p6/1R2N1p1/3kp1P1/8/5P2/3N1Pp1/6Kb w - - 0 1
Right answer Ne4 mate in 4 move NCM showing Kg2 mate in 10 move

You don’t need a computer to tell that a8=Q is the best move
If you were looking for a mate in one you should have flipped the board.