When is it the right time to resign a lost position?
Resign when you have no hope.
As long as you have hope, play on, even a queen down.
https://www.chessgames.com/perl/chessgame?gid=1008376

Yes. When grandmasters are down 2 pawns they usually resign. Think of it this way:If you are a rook or queen up and you trade all the pawns you will win easily. Being up a minor piece is always decisive if there are pawns on the board. If there are no pawns and you are up a minor piece you are usually not going to win. I would play on if you are only down a pawn or two. If you are down a rook or queen you can safely resign. By not resigning you are wasting your time. Your opponent will not carelessly stalemate you or get a heart attack and lose on time.

Being a queen or rook up is ALWAYS easily winning for the stronger side. If you lose your queen for free or for a minor piece, immediately resign. If you lose your rook for free resign.
I resign the moment I lose my rook or queen. I just want to ask if resigning when I lose my queen or rook is right?