The joint resource block (RB) allocation and power optimization problem is studied to maximize the sum-rate of the vehicle-to-vehicle (V2V) links in the device-to-device (D2D)-enabled V2V communication system, where one feasible cellular user (FCU) can share its RB with multiple V2V pairs. The problem is first formulated as a nonconvex mixed-integer nonlinear programming (MINLP) problem with constraint of the maximum interference power in the FCU links. Using the game theory, two coalition formation algorithms are proposed to accomplish V2V link partitioning and FCU selection, where the transferable utility functions are introduced to minimize the interference among the V2V links and the FCU links for the optimal RB allocation. The successive convex approximation (SCA) is used to transform the original problem into a convex one and the Lagrangian dual method is further applied to obtain the optimal transmit power of the V2V links. Finally, numerical results demonstrate the efficiency of the proposed resource allocation algorithm in terms of the system sum-rate.