>this is dangerous and need to get 3 prong installation so that the electrical circuits are grounded??
If you want to plug in anything that is three prong, yes, absolutely.

>I also would like to know how much something like this would cost as I live in a small 2 bedroom house.
The wiring probably needs to be replaced.

>Would like to know if this is necessary.
Yes. You may also consider using GFCI receptacles and test them monthly. You should also get GFCI receptacles in your kitchen, bath, and laundry for your own protection.

You need an electrician to look for other problems such as undersized wiring, reversed polarity, and oversized OCPDs.

>would like to know if this is against any electrical code violations of the seller who sold me this house
That is not likely.