Edit in JSFiddle

<body>
<table border="1" align="center" width="40%">
<caption>Employee Details</caption>
<colgroup id="k1" span="2">
</colgroup>
<colgroup id="k2">
</colgroup>
<tr>
<th>EmpId</th>
<th>Name</th>
<th>Department</th>
</tr>
<tr>
<td>1001</td>
<td>Gurdeep</td>
<td>Testing</td>
</tr>
<tr>
<td>1002</td>
<td>Roschelle</td>
<td>DBA</td>
</tr>
</table>
</body>
#k1
{
background-color:skyblue;
color:blue;
}
#k2
{
background-color:yellow;
color:red;
}