you can consider me new to GIMP. I've tried by holding Shift key, can draw straight line but I want a straight horizontal/vertical line. So, How can I draw straight vertical/horizontal line?
I would create a horizontal (or vertical) guide were you want the line (with the menu Image/Guides/New Guide), then use the path tool (shortcut B).
Click on the guide where you want the first point of the segment, then click on where you want the second point of the segment. The guide will ensure the two points are aligned.
When done, click on "Stroke Path" in the tools pane and select the paint tool you want the line draw with.
Alternatively you can set the grid with the proper size and use the path tool again. I prefer guides as they are more flexible, but it depends on what you are drawing.
You won't be able to modify the line after it has been drawn as GIMP deals with bitmap images only.