If I'm reading this question correctly and it is x/(2x + 3xy), the first method is wrong. Not sure how you got 1/5y. The second is correct. You need to factor x out and cancel it with the one in the numerator to get 1/2+3y
Those two are not the same actually

x/(2x + 3xy) = x/[(2+3y)(x)] = 1/[2+3x]

The only possible way you can obtain 1/5y is if it were (2xy+3xy) in the denominator. Like you cannot add 2x and 3xy together

2x + 3x = 5x

2x + 3xy is not equal to 5xy